Fix: remove unnecessary reassigment

This commit is contained in:
Xaz16
2019-12-29 20:58:10 +03:00
parent 4b4cc61031
commit 2c65b3a6a3

View File

@@ -124,10 +124,8 @@ export default function randomDrop (user, options, req = {}, analytics) {
...user.items.hatchingPotions,
[drop.key]: user.items.hatchingPotions[drop.key] || 0,
};
user.items.hatchingPotions = {
...user.items.hatchingPotions,
[drop.key]: drop.key + 1,
};
user.items.hatchingPotions[drop.key] += 1;
if (user.markModified) user.markModified('items.hatchingPotions');
drop.type = 'HatchingPotion';