Skip to content

Commit 050d8c7

Browse files
committed
fix config saving
once again, bugs! Signed-off-by: aelithron <aelithron@gmail.com>
1 parent c393ccb commit 050d8c7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/main/java/com/aelithron/secretsanta/SecretSanta.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,9 @@ public void onInvClose(InventoryCloseEvent e) {
7777
List<ItemStack> gifts = CoreTools.getInstance().deserializeGifts(gifteeUUID);
7878
if (gifts == null) { return; }
7979
for (ItemStack gift : gifts) { e.getPlayer().getInventory().addItem(gift); }
80+
reloadConfig();
8081
getConfig().set("SecretSanta." + gifteeUUID + ".claimed", true);
82+
saveConfig();
8183
e.getPlayer().sendMessage(CoreTools.getInstance().getPrefix() + ChatColor.GREEN + "Your gift has been delivered!");
8284
return;
8385
}

0 commit comments

Comments
 (0)