1
0
mirror of https://github.com/Zrips/Jobs.git synced 2024-11-25 20:16:13 +01:00

Fix money dupping issue (not full)

Related issue: #438
This commit is contained in:
montlikadani 2019-05-30 20:03:09 +02:00
parent 23e349bd10
commit 2a93f1b461

View File

@ -807,6 +807,11 @@ public class JobsPaymentListener implements Listener {
if (!payIfCreative(player)) if (!payIfCreative(player))
return; return;
// Fix money dupping issue when clicking continuously in the result item, but if in the
// cursor have item, then dupping the money, #438
if (event.isLeftClick() && !player.getInventory().contains(inv.getItem(2)))
return;
JobsPlayer jPlayer = Jobs.getPlayerManager().getJobsPlayer(player); JobsPlayer jPlayer = Jobs.getPlayerManager().getJobsPlayer(player);
if (jPlayer == null) if (jPlayer == null)
return; return;