mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-26 19:41:11 +00:00
Ignore pylint complaints about argument counts to form saves
This commit is contained in:
parent
35aebacf70
commit
7d61cb55bc
2 changed files with 2 additions and 0 deletions
|
@ -141,6 +141,7 @@ class IntervalScheduleForm(StyledForm):
|
|||
"period": forms.Select(attrs={"aria-describedby": "desc_period"}),
|
||||
}
|
||||
|
||||
# pylint: disable=arguments-differ
|
||||
def save(self, request, *args, **kwargs):
|
||||
"""This is an outside model so the perms check works differently"""
|
||||
if not request.user.has_perm("bookwyrm.moderate_user"):
|
||||
|
|
|
@ -29,6 +29,7 @@ class StyledForm(ModelForm):
|
|||
class CustomForm(StyledForm):
|
||||
"""Check permissions on save"""
|
||||
|
||||
# pylint: disable=arguments-differ
|
||||
def save(self, request, *args, **kwargs):
|
||||
"""Save and check perms"""
|
||||
self.instance.raise_not_editable(request.user)
|
||||
|
|
Loading…
Reference in a new issue