diff --git a/build.gradle b/build.gradle index bd5c7f4a..fdb22c2c 100644 --- a/build.gradle +++ b/build.gradle @@ -43,7 +43,7 @@ dependencies { api 'com.epam.reportportal:commons-dao' api 'com.epam.reportportal:commons' } else { - api 'com.github.reportportal:commons-dao:develop-SNAPSHOT' + api 'com.github.reportportal:commons-dao:c6784ce' api 'com.github.reportportal:commons:develop-SNAPSHOT' } diff --git a/src/main/java/com/epam/reportportal/auth/event/UiAuthenticationSuccessEventHandler.java b/src/main/java/com/epam/reportportal/auth/event/UiAuthenticationSuccessEventHandler.java index b62d10ea..7594440a 100644 --- a/src/main/java/com/epam/reportportal/auth/event/UiAuthenticationSuccessEventHandler.java +++ b/src/main/java/com/epam/reportportal/auth/event/UiAuthenticationSuccessEventHandler.java @@ -24,7 +24,6 @@ import com.epam.ta.reportportal.entity.project.Project; import com.epam.ta.reportportal.entity.user.User; import com.epam.ta.reportportal.util.PersonalProjectService; -import java.time.Instant; import org.apache.commons.collections4.MapUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.event.EventListener; @@ -61,9 +60,7 @@ public void onApplicationEvent(UiUserSignedInEvent event) { SecurityContextHolder.clearContext(); throw new LockedException("User account is locked"); } - userRepository.updateLastLoginDate( - Instant.ofEpochMilli(event.getTimestamp()), - username); + userRepository.updateLastLoginDate(username); if (MapUtils.isEmpty(acquireUser(event.getAuthentication()).getProjectDetails())) { User user = userRepository.findByLogin(username)