Skip to content

Commit b33968e

Browse files
committed
Remove get_form which wasn't used
1 parent 44b0a57 commit b33968e

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

readthedocs/core/forms.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
from django import forms
66
from django.forms.fields import CharField
77
from django.utils.translation import ugettext_lazy as _
8-
from models import UserProfile
8+
9+
from .models import UserProfile
910

1011
log = logging.getLogger(__name__)
1112

@@ -40,10 +41,12 @@ def save(self, *args, **kwargs):
4041

4142

4243
class FacetField(forms.MultipleChoiceField):
44+
4345
'''
4446
For filtering searches on a facet, with validation for the format
4547
of facet values.
4648
'''
49+
4750
def valid_value(self, value):
4851
'''
4952
Although this is a choice field, no choices need to be supplied.
@@ -56,6 +59,7 @@ def valid_value(self, value):
5659

5760

5861
class FacetedSearchForm(SearchForm):
62+
5963
'''
6064
Supports fetching faceted results with a corresponding query.
6165

readthedocs/core/models.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212

1313

1414
class UserProfile (models.Model):
15+
1516
"""Additional information about a User.
1617
"""
1718
user = models.OneToOneField('auth.User', verbose_name=_('User'),
@@ -27,10 +28,6 @@ def __unicode__(self):
2728
return (ugettext("%(username)s's profile")
2829
% {'username': self.user.username})
2930

30-
def get_form(self):
31-
from .forms import UserProfileForm
32-
return UserProfileForm(instance=self)
33-
3431
def get_absolute_url(self):
3532
return ('profiles_profile_detail', (),
3633
{'username': self.user.username})

0 commit comments

Comments
 (0)