Skip to content

Commit

Permalink
release v0.12.4
Browse files Browse the repository at this point in the history
  • Loading branch information
utnapischtim committed Jul 29, 2024
1 parent 5d84b08 commit cbe286b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@
Changes
=======

Version v0.12.4 (release 2024-07-29)

- fix: permission for ip


Version v0.12.3 (release 2024-07-25)

- fix(tugraz_authenticated): missmatch of role name
Expand Down
2 changes: 1 addition & 1 deletion invenio_config_tugraz/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
from .ext import InvenioConfigTugraz
from .utils import get_identity_from_user_by_email

__version__ = "0.12.3"
__version__ = "0.12.4"

__all__ = (
"__version__",
Expand Down
2 changes: 2 additions & 0 deletions invenio_config_tugraz/permissions/generators.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ class AllowedFromIPNetwork(Generator):

def needs(self, record: dict | None = None, **__: dict) -> list[Need]:
"""Set of Needs granting permission. Enabling Needs."""
print("AllowedFromIPNetwork.needs")
if record is None:
return []

Expand All @@ -142,6 +143,7 @@ def needs(self, record: dict | None = None, **__: dict) -> list[Need]:
record.get("custom_fields", {}).get("ip_network", False)
and self.check_permission()
):
print("AllowedFromIPNetwork.needs if")
return [any_user]

# non of the above - return empty
Expand Down

0 comments on commit cbe286b

Please sign in to comment.