Permalink
Browse files

Hotfix for infinite quests

  • Loading branch information...
casid committed Mar 29, 2016
1 parent 072bc80 commit d860e7cc920d1fa1ae964391b46adc7391a00cfb
@@ -97,12 +97,13 @@ public int findPlayerRank(long id) {
@Override
public void updatePlayer(Player player) {
try {
getQueryRunner().update("UPDATE Player SET level=?, experience=?, lastUpdate=?, email=?, supporterLevel=? WHERE id=?;",
getQueryRunner().update("UPDATE Player SET level=?, experience=?, lastUpdate=?, email=?, supporterLevel=?, lastQuestCreation=? WHERE id=?;",
player.getLevel(),
player.getExperience(),
player.getLastUpdate(),
player.getEmail(),
player.getSupporterLevel(),
player.getLastQuestCreation(),
player.getId()
);
} catch (SQLException e) {
@@ -174,6 +174,7 @@ public void updatePlayer_valuesAreUpdated() {
.withLastUpdate(a(date().with("2016-02-02 23:00:11")))
.withEmail("anonymous@mazebert.com")
.withSupporterLevel(100)
.withLastQuestCreation(a(date().with("2016-04-01 14:00:00")))
));
Player updated = gateway.findPlayerByKey(existing.getKey());
@@ -182,6 +183,7 @@ public void updatePlayer_valuesAreUpdated() {
assertEquals(a(date().with("2016-02-02 23:00:11")), updated.getLastUpdate());
assertEquals("anonymous@mazebert.com", updated.getEmail());
assertEquals(100, updated.getSupporterLevel());
assertEquals(a(date().with("2016-04-01 14:00:00")), updated.getLastQuestCreation());
}
@Test

0 comments on commit d860e7c

Please sign in to comment.