Skip to content

Commit 63397af

Browse files
authored
Fixed a regression and an issue
1 parent a909b63 commit 63397af

File tree

1 file changed

+2
-2
lines changed
  • addons/source-python/packages/source-python/entities

1 file changed

+2
-2
lines changed

addons/source-python/packages/source-python/entities/hooks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,15 @@ def __call__(self, callback):
102102
for entity in EntityIter():
103103
if self.initialize(entity):
104104
# Yay! The entity was the one we were looking for
105-
return self
105+
return self.callback
106106

107107
# Initialization failed. There is currently no entity with the given
108108
# class name. So, we need to wait until such an entity has been
109109
# created.
110110
_waiting_entity_hooks.append(self)
111111

112112
# Return the callback
113-
return self
113+
return self.callback
114114

115115
@property
116116
def hook_type(self):

0 commit comments

Comments
 (0)