fix ApplicationBase::TryGetComponent

This commit is contained in:
SweetId 2024-03-24 20:45:42 -04:00
parent e306a66956
commit 2ccc5c364c
1 changed files with 2 additions and 2 deletions

View File

@ -97,7 +97,7 @@ namespace Nz
constexpr UInt64 typeHash = FNV1a64(TypeName<T>());
auto it = m_components.find(typeHash);
if (it != m_components.end())
if (it == m_components.end())
return nullptr;
return static_cast<T*>(it->second.get());
@ -109,7 +109,7 @@ namespace Nz
constexpr UInt64 typeHash = FNV1a64(TypeName<T>());
auto it = m_components.find(typeHash);
if (it != m_components.end())
if (it == m_components.end())
return nullptr;
return static_cast<const T*>(it->second.get());