Skip to content

Commit

Permalink
This seems cleaner
Browse files Browse the repository at this point in the history
  • Loading branch information
danielhollas committed Oct 10, 2023
1 parent d77e464 commit 9a8e308
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions aiida/plugins/entry_point.py
Original file line number Diff line number Diff line change
Expand Up @@ -349,13 +349,8 @@ def get_entry_point_from_class(class_module: str, class_name: str) -> Tuple[Opti
:return: a tuple of the corresponding group and entry point or None if not found
"""
for entry_point in eps():

if entry_point.module != class_module:
continue

if entry_point.attr == class_name:
if entry_point.module == class_module and entry_point.attr == class_name:
return entry_point.group, entry_point

return None, None


Expand Down

0 comments on commit 9a8e308

Please sign in to comment.