diff options
author | Petr Ilin <hevav@hevav.dev> | 2022-05-15 16:36:18 +0300 |
---|---|---|
committer | Petr Ilin <hevav@hevav.dev> | 2022-05-15 16:36:18 +0300 |
commit | 35d932ddfa02e2fc5236dcf07c1606b73b6e3585 (patch) | |
tree | 98fbd304e59962dba5f8fa41b482df26875b0e20 /src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java | |
parent | fdaa89826db5e9f585c6c69e85624b0a449c5372 (diff) | |
download | LimboAuth-35d932ddfa02e2fc5236dcf07c1606b73b6e3585.tar.gz LimboAuth-35d932ddfa02e2fc5236dcf07c1606b73b6e3585.tar.bz2 LimboAuth-35d932ddfa02e2fc5236dcf07c1606b73b6e3585.zip |
More secure SQLExceptions handling
Diffstat (limited to 'src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java')
-rw-r--r-- | src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java b/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java index 4e330ce..9a795b5 100644 --- a/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java +++ b/src/main/java/net/elytrium/limboauth/handler/AuthSessionHandler.java @@ -228,6 +228,7 @@ public class AuthSessionHandler implements LimboSessionHandler { playerDao.update(player); } catch (SQLException e) { e.printStackTrace(); + return false; } } } @@ -258,6 +259,7 @@ public class AuthSessionHandler implements LimboSessionHandler { sizeOfValid.decrementAndGet(); } catch (SQLException ex) { ex.printStackTrace(); + this.proxyPlayer.disconnect(this.deserialize(Settings.IMP.MAIN.STRINGS.DB_ERROR)); } }); } @@ -267,6 +269,7 @@ public class AuthSessionHandler implements LimboSessionHandler { } } catch (SQLException e) { e.printStackTrace(); + this.proxyPlayer.disconnect(this.deserialize(Settings.IMP.MAIN.STRINGS.DB_ERROR)); } } @@ -292,6 +295,7 @@ public class AuthSessionHandler implements LimboSessionHandler { this.playerDao.create(registeredPlayer); } catch (SQLException e) { e.printStackTrace(); + this.proxyPlayer.disconnect(this.deserialize(Settings.IMP.MAIN.STRINGS.DB_ERROR)); } } |