diff options
Diffstat (limited to 'gitlab/v4/objects/triggers.py')
-rw-r--r-- | gitlab/v4/objects/triggers.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/gitlab/v4/objects/triggers.py b/gitlab/v4/objects/triggers.py index f203d93..6ff2517 100644 --- a/gitlab/v4/objects/triggers.py +++ b/gitlab/v4/objects/triggers.py @@ -1,3 +1,5 @@ +from typing import Any, cast, Union + from gitlab.base import RequiredOptional, RESTManager, RESTObject from gitlab.mixins import CRUDMixin, ObjectDeleteMixin, SaveMixin @@ -17,3 +19,8 @@ class ProjectTriggerManager(CRUDMixin, RESTManager): _from_parent_attrs = {"project_id": "id"} _create_attrs = RequiredOptional(required=("description",)) _update_attrs = RequiredOptional(required=("description",)) + + def get( + self, id: Union[str, int], lazy: bool = False, **kwargs: Any + ) -> ProjectTrigger: + return cast(ProjectTrigger, super().get(id=id, lazy=lazy, **kwargs)) |