diff --git a/src/game/game.cpp b/src/game/game.cpp index 7cffc924a0b..7ddfc190bc7 100644 --- a/src/game/game.cpp +++ b/src/game/game.cpp @@ -9239,7 +9239,7 @@ void Game::removeGuild(uint32_t guildId) { guilds.erase(guildId); } -void Game::internalRemoveItems(const std::vector> itemVector, uint32_t amount, bool stackable) { +void Game::internalRemoveItems(const std::vector>& itemVector, uint32_t amount, bool stackable) { if (stackable) { for (std::shared_ptr item : itemVector) { if (item->getItemCount() > amount) { diff --git a/src/game/game.hpp b/src/game/game.hpp index cce1c21e5a3..427d51d8d16 100644 --- a/src/game/game.hpp +++ b/src/game/game.hpp @@ -498,7 +498,7 @@ class Game { phmap::flat_hash_map, std::weak_ptr> browseFields; - void internalRemoveItems(const std::vector> itemVector, uint32_t amount, bool stackable); + void internalRemoveItems(const std::vector>& itemVector, uint32_t amount, bool stackable); std::shared_ptr getBedBySleeper(uint32_t guid) const; void setBedSleeper(std::shared_ptr bed, uint32_t guid);