소스 검색

代码优化

woody 4 달 전
부모
커밋
728294722d
1개의 변경된 파일1개의 추가작업 그리고 4개의 파일을 삭제
  1. 1 4
      framework-base/src/main/java/com/chelvc/framework/base/interceptor/VersionControlInterceptor.java

+ 1 - 4
framework-base/src/main/java/com/chelvc/framework/base/interceptor/VersionControlInterceptor.java

@@ -54,9 +54,6 @@ public class VersionControlInterceptor implements HandlerInterceptor, WebMvcConf
                     if (environment != null && StringUtils.notEmpty(message)) {
                         message = environment.resolvePlaceholders(message);
                     }
-                    if (StringUtils.isEmpty(message)) {
-                        message = ApplicationContextHolder.getMessage("Version.Control.Limit");
-                    }
                     throw new ResourceUnavailableException(message);
                 }
             }
@@ -65,7 +62,7 @@ public class VersionControlInterceptor implements HandlerInterceptor, WebMvcConf
         // 终端最低版本配置校验
         String minimum = ApplicationContextHolder.getProperty(terminal.name().toLowerCase() + ".version.minimum");
         if (StringUtils.notEmpty(minimum) && !SessionContextHolder.isAfterVersion(terminal, minimum, true)) {
-            throw new ResourceUnavailableException(ApplicationContextHolder.getMessage("Version.Control.Limit"));
+            throw new ResourceUnavailableException(ApplicationContextHolder.getMessage("Version.Minimum.Limit"));
         }
         return true;
     }