Skip to content

Commit

Permalink
Remove superfluous set_flat_form_attributes calls
Browse files Browse the repository at this point in the history
Since they don't set anything we can as well remove them
  • Loading branch information
johannaengland committed Oct 11, 2024
1 parent 86be235 commit aac8716
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions python/nav/web/seeddb/page/service/edit.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@

from nav.models.service import Service, ServiceProperty
from nav.models.manage import Netbox
from nav.web.crispyforms import set_flat_form_attributes
from nav.web.servicecheckers import get_description, load_checker_classes
from nav.web.message import new_message, Messages
from nav.web.seeddb.page.service import ServiceInfo
Expand All @@ -45,8 +44,6 @@ def __init__(self, *args, **kwargs):
widget=forms.Select(attrs={'class': 'select2'}),
)

self.attrs = set_flat_form_attributes()

@staticmethod
def _build_checker_choices():
checkers = load_checker_classes()
Expand Down Expand Up @@ -75,8 +72,6 @@ class ServiceForm(forms.Form):
handler = forms.CharField(widget=forms.HiddenInput)
netbox = forms.IntegerField(widget=forms.HiddenInput)

attrs = set_flat_form_attributes()


class ServicePropertyForm(forms.Form):
"""Form for editing service properties"""
Expand All @@ -94,8 +89,6 @@ def __init__(self, *args, **kwargs):
for arg, descr in opt_args:
self.fields[arg] = forms.CharField(required=False, help_text=descr)

self.attrs = set_flat_form_attributes()


def service_edit(request, service_id=None):
"""Controller for editing services"""
Expand Down

0 comments on commit aac8716

Please sign in to comment.