diff --git a/api/src/main/java/com/databasir/api/config/security/DatabasirAuthenticationSuccessHandler.java b/api/src/main/java/com/databasir/api/config/security/DatabasirAuthenticationSuccessHandler.java index af36496..220bd73 100644 --- a/api/src/main/java/com/databasir/api/config/security/DatabasirAuthenticationSuccessHandler.java +++ b/api/src/main/java/com/databasir/api/config/security/DatabasirAuthenticationSuccessHandler.java @@ -48,7 +48,7 @@ public class DatabasirAuthenticationSuccessHandler implements AuthenticationSucc data.setId(user.getUserPojo().getId()); data.setNickname(user.getUserPojo().getNickname()); data.setEmail(user.getUserPojo().getEmail()); - data.setUsername(user.getUsername()); + data.setUsername(user.getUserPojo().getUsername()); LoginKeyResponse loginKey = loginService.generate(user.getUserPojo().getId()); data.setAccessToken(loginKey.getAccessToken()); diff --git a/api/src/main/resources/application-local.properties b/api/src/main/resources/application-local.properties index 8f47aef..b3da7a4 100644 --- a/api/src/main/resources/application-local.properties +++ b/api/src/main/resources/application-local.properties @@ -6,6 +6,6 @@ spring.datasource.password=123456 spring.datasource.url=jdbc:mysql://localhost:3306/databasir spring.jooq.sql-dialect=mysql -spring.flyway.enabled=false +spring.flyway.enabled=true spring.flyway.baseline-on-migrate=true spring.flyway.locations=classpath:db/migration \ No newline at end of file