Skip to content

Commit

Permalink
Fixed obsolete super() syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
claudep committed Sep 20, 2020
1 parent 143d7de commit ebaeb9c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docs/usage.rst
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ the link dialog you could use something like this::
attrs={'cols': 80, 'rows': 30},
mce_attrs={'external_link_list_url': reverse('tinymce-linklist')},
))
return super(TinyMCEFlatPageAdmin, self).formfield_for_dbfield(db_field, **kwargs)
return super().formfield_for_dbfield(db_field, **kwargs)

somesite.register(FlatPage, TinyMCEFlatPageAdmin)

Expand Down
6 changes: 3 additions & 3 deletions testtinymce/testapp/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def formfield_for_dbfield(self, db_field, **kwargs):
mce_attrs={"external_link_list_url": reverse("tinymce-linklist")},
)
)
return super(TinyMCETestInlineAdmin, self).formfield_for_dbfield(db_field, **kwargs)
return super().formfield_for_dbfield(db_field, **kwargs)


class TinyMCEFlatPageAdmin(FlatPageAdmin):
Expand All @@ -31,7 +31,7 @@ def formfield_for_dbfield(self, db_field, **kwargs):
mce_attrs={"external_link_list_url": reverse("tinymce-linklist")},
)
)
return super(TinyMCEFlatPageAdmin, self).formfield_for_dbfield(db_field, **kwargs)
return super().formfield_for_dbfield(db_field, **kwargs)


class TinyMCETestPageAdmin(admin.ModelAdmin):
Expand All @@ -45,7 +45,7 @@ def formfield_for_dbfield(self, db_field, **kwargs):
mce_attrs={"external_link_list_url": reverse("tinymce-linklist")},
)
)
return super(TinyMCETestPageAdmin, self).formfield_for_dbfield(db_field, **kwargs)
return super().formfield_for_dbfield(db_field, **kwargs)


admin.site.unregister(FlatPage)
Expand Down
2 changes: 1 addition & 1 deletion tinymce/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ def formfield(self, **kwargs):
if defaults["widget"] == admin_widgets.AdminTextareaWidget:
defaults["widget"] = tinymce_widgets.AdminTinyMCE

return super(HTMLField, self).formfield(**defaults)
return super().formfield(**defaults)

0 comments on commit ebaeb9c

Please sign in to comment.