Skip to content

Commit 4bd7877

Browse files
committed
Fixed a bug in WeaponClass.item_definition_index.
1 parent 22a661f commit 4bd7877

File tree

1 file changed

+1
-1
lines changed
  • addons/source-python/packages/source-python/weapons

1 file changed

+1
-1
lines changed

addons/source-python/packages/source-python/weapons/instance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ def item_definition_index(self):
170170
None if the item defition index data is missing.
171171
:rtype: int
172172
"""
173-
return int(self._id)
173+
return int(self._id) if self._id is not None else None
174174

175175
@property
176176
def tags(self):

0 commit comments

Comments
 (0)