mirror of
https://gitee.com/durcframework/SOP.git
synced 2025-08-11 21:57:56 +08:00
修复获取Locale空问题
This commit is contained in:
@@ -31,7 +31,11 @@ public class ServiceContext extends ConcurrentHashMap<String, Object> {
|
||||
}
|
||||
|
||||
public Locale getLocale() {
|
||||
return getRequest().getLocale();
|
||||
HttpServletRequest request = getRequest();
|
||||
if (request == null) {
|
||||
return Locale.SIMPLIFIED_CHINESE;
|
||||
}
|
||||
return request.getLocale();
|
||||
}
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user