aboutsummaryrefslogtreecommitdiff
path: root/src/crepe/ComponentManager.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/crepe/ComponentManager.hpp')
-rw-r--r--src/crepe/ComponentManager.hpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/crepe/ComponentManager.hpp b/src/crepe/ComponentManager.hpp
index e52b679..7616f92 100644
--- a/src/crepe/ComponentManager.hpp
+++ b/src/crepe/ComponentManager.hpp
@@ -88,7 +88,8 @@ ComponentManager::get_components_by_id(uint32_t id) const {
// Create an empty vector<>
vector<reference_wrapper<T>> component_vector;
- if (this->components.find(type) == this->components.end()) return component_vector;
+ if (this->components.find(type) == this->components.end())
+ return component_vector;
// Get the correct vector<>
const vector<vector<unique_ptr<Component>>> & component_array
@@ -123,7 +124,8 @@ ComponentManager::get_components_by_type() const {
vector<reference_wrapper<T>> component_vector;
// Find the type (in the unordered_map<>)
- if (this->components.find(type) == this->components.end()) return component_vector;
+ if (this->components.find(type) == this->components.end())
+ return component_vector;
// Get the correct vector<>
const vector<vector<unique_ptr<Component>>> & component_array