printStackTrace to LOGGER

This commit is contained in:
brenoepic 2022-04-29 16:54:20 -03:00
parent 36fed88ea9
commit 6f74f80336

View File

@ -44,10 +44,12 @@ public class ChangeUsername extends RCONMessage<ChangeUsername.JSON> {
success = statement.executeUpdate() >= 1; success = statement.executeUpdate() >= 1;
} catch (SQLException sqlException) { } catch (SQLException sqlException) {
sqlException.printStackTrace(); this.message = "SQL Exception occurred";
LOGGER.error(this.message, sqlException);
} }
} catch (SQLException sqlException) { } catch (SQLException sqlException) {
sqlException.printStackTrace(); this.message = "SQL Exception occurred";
LOGGER.error(this.message, sqlException);
} }
} }
@ -57,7 +59,7 @@ public class ChangeUsername extends RCONMessage<ChangeUsername.JSON> {
catch (Exception e) { catch (Exception e) {
this.status = RCONMessage.SYSTEM_ERROR; this.status = RCONMessage.SYSTEM_ERROR;
this.message = "Exception occurred"; this.message = "Exception occurred";
LOGGER.error("Exception occurred", e); LOGGER.error(this.message, e);
} }
} }