summaryrefslogtreecommitdiffstats
path: root/src/AssetManager.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/AssetManager.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/AssetManager.cpp b/src/AssetManager.cpp
index e3e0e05..63dc596 100644
--- a/src/AssetManager.cpp
+++ b/src/AssetManager.cpp
@@ -658,9 +658,7 @@ BlockFaces &AssetManager::GetBlockModelByBlockId(BlockId block) {
blockFaces.faceDirectionVector[i] = Vector(roundf(vec.x), roundf(vec.y), roundf(vec.z));
}
- blockIdToBlockFaces.insert(std::make_pair(block, blockFaces));
-
- return blockIdToBlockFaces.find(block)->second;
+ return blockIdToBlockFaces.insert(std::make_pair(block, blockFaces)).first->second;
}
std::string AssetManager::GetAssetNameByBlockId(BlockId block) {