diff --git a/apps/openmw/mwworld/store.cpp b/apps/openmw/mwworld/store.cpp index 2d084e70ce..280c682d70 100644 --- a/apps/openmw/mwworld/store.cpp +++ b/apps/openmw/mwworld/store.cpp @@ -902,9 +902,7 @@ namespace MWWorld // we assume that these records are empty on purpose (i.e. to remove old pathgrid on an updated cell) if (isDeleted || pathgrid.mPoints.empty() || pathgrid.mEdges.empty()) { - auto it = mStatic.find(cell); - if (it != mStatic.end()) - mStatic.erase(it); + mStatic.erase(cell); return RecordId(ESM::RefId(), isDeleted); } diff --git a/apps/openmw/mwworld/store.hpp b/apps/openmw/mwworld/store.hpp index 4494b71bc6..58636acdb6 100644 --- a/apps/openmw/mwworld/store.hpp +++ b/apps/openmw/mwworld/store.hpp @@ -414,7 +414,6 @@ namespace MWWorld class Store : public DynamicStore { private: - std::unordered_map mStatic; Store* mCells;