|
@@ -9,7 +9,7 @@ import java.util.Map;
|
|
|
|
|
|
|
|
|
|
public class AbstractExceptionHandler {
|
|
public class AbstractExceptionHandler {
|
|
- private static String DEFAULT_ERROR_CODE = "500";
|
|
|
|
|
|
+ private static long DEFAULT_ERROR_CODE = 500;
|
|
|
|
|
|
protected String formatMessage(Throwable ex) {
|
|
protected String formatMessage(Throwable ex) {
|
|
|
|
|
|
@@ -23,7 +23,7 @@ public class AbstractExceptionHandler {
|
|
} else if (ex instanceof ApiException) {
|
|
} else if (ex instanceof ApiException) {
|
|
ApiException exception = (ApiException) ex;
|
|
ApiException exception = (ApiException) ex;
|
|
errorMessage = exception.getMessage();
|
|
errorMessage = exception.getMessage();
|
|
- DEFAULT_ERROR_CODE = exception.getErrorCode().getCode() + "";
|
|
|
|
|
|
+ DEFAULT_ERROR_CODE = exception.getErrorCode().getCode();
|
|
} else {
|
|
} else {
|
|
errorMessage = ex.getMessage();
|
|
errorMessage = ex.getMessage();
|
|
}
|
|
}
|