Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Jan 29, 2024
1 parent c09b7c8 commit 24aefa3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
6 changes: 3 additions & 3 deletions model_clone/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ class CloneModelAdminMixin(object):

def change_view(self, request, object_id, form_url="", extra_context=None):
extra_context = extra_context or {}
extra_context[
"include_duplicate_object_link"
] = self.include_duplicate_object_link
extra_context["include_duplicate_object_link"] = (
self.include_duplicate_object_link
)
if self.include_duplicate_object_link:
to_field = request.POST.get(TO_FIELD_VAR, request.GET.get(TO_FIELD_VAR))
if to_field and not self.to_field_allowed(request, to_field):
Expand Down
1 change: 0 additions & 1 deletion model_clone/mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@


class CloneMixin(object):

"""CloneMixin mixin to duplicate an object using the model's class.
:param _clone_fields: Restricted List of fields to copy from the instance.
Expand Down

0 comments on commit 24aefa3

Please sign in to comment.