diff options
Diffstat (limited to 'src/common/singleton.h')
-rw-r--r-- | src/common/singleton.h | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/common/singleton.h b/src/common/singleton.h index 841759d..bf5bc9d 100644 --- a/src/common/singleton.h +++ b/src/common/singleton.h @@ -62,10 +62,7 @@ public: static void ReplaceInstance(T* newInstance) { assert(newInstance != nullptr); - - if (m_instance != nullptr) - delete m_instance; - + delete m_instance; m_instance = newInstance; } #endif |