- def get(self, *args, **kwargs):
- return super(ActionQuerySet, self).get(*args, **kwargs).leaf()
+ def get(self, *args, **kwargs):
+ action = super(ActionQuerySet, self).get(*args, **kwargs).leaf()
+
+ if not isinstance(action, self.model):
+ raise self.model.DoesNotExist()
+
+ return action