Skip to content

Commit

Permalink
Bug in StatusUpdate found and marked
Browse files Browse the repository at this point in the history
  • Loading branch information
bm committed Jul 2, 2018
1 parent 3b0c9e2 commit b3ff14a
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import java.util.List;

import org.hibernate.Session;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

Expand Down Expand Up @@ -42,6 +43,8 @@ public void updateStandardTasks(final World world) {
}

public StandardTask updateStandardTask(final StandardTask task) {
//FIXME - will not work with Hibernate/Spring-caching - when task is updated Hibernate will return new value here!
//so SOLVED will always be old and new Status with no rewards given
final StandardTask lastState = standardTaskRepository.findByKey(task.getKey());
if (lastState != null) {
final SonarQuestStatus newStatus = SonarQuestStatus.fromStatusText(task.getStatus());
Expand Down

0 comments on commit b3ff14a

Please sign in to comment.