fix
This commit is contained in:
parent
4bff439291
commit
3c68bbff1a
2
pom.xml
2
pom.xml
@ -10,7 +10,7 @@
|
|||||||
<properties>
|
<properties>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<java.version>11</java.version>
|
<java.version>11</java.version>
|
||||||
<revision>0.4.1-SNAPSHOT</revision>
|
<revision>0.4.2-SNAPSHOT</revision>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
|
@ -73,7 +73,8 @@ public class BaseController {
|
|||||||
Authentication auth = SecurityContextHolder.getContext().getAuthentication();
|
Authentication auth = SecurityContextHolder.getContext().getAuthentication();
|
||||||
if (auth != null && auth.isAuthenticated()) {
|
if (auth != null && auth.isAuthenticated()) {
|
||||||
LocalUser localUser = localUserManager.getByAuth(auth);
|
LocalUser localUser = localUserManager.getByAuth(auth);
|
||||||
if (localUser.getSettings() != null && localUser.getSettings().containsKey("gravity")) {
|
if (localUser != null && localUser.getSettings() != null
|
||||||
|
&& localUser.getSettings().containsKey("gravity")) {
|
||||||
try {
|
try {
|
||||||
return Double.parseDouble(localUser.getSettings().get("gravity"));
|
return Double.parseDouble(localUser.getSettings().get("gravity"));
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user