aboutsummaryrefslogtreecommitdiffstats
path: root/servo/forms
diff options
context:
space:
mode:
authorFilipp Lepalaan <filipp@mac.com>2021-05-12 20:58:01 +0300
committerFilipp Lepalaan <filipp@mac.com>2021-05-12 20:58:01 +0300
commit64babb6918fe038e8a94353117fb869e4db41f02 (patch)
tree17a5e1cb0213322191eee268b7e0344ac171324f /servo/forms
parent9326a6be300577965f7378bffbf6771240f52ad5 (diff)
downloadServo-64babb6918fe038e8a94353117fb869e4db41f02.tar.gz
Servo-64babb6918fe038e8a94353117fb869e4db41f02.tar.bz2
Servo-64babb6918fe038e8a94353117fb869e4db41f02.zip
Django 3 fixes
Diffstat (limited to 'servo/forms')
-rw-r--r--servo/forms/checkin.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/servo/forms/checkin.py b/servo/forms/checkin.py
index 8cd19c4..c8429a9 100644
--- a/servo/forms/checkin.py
+++ b/servo/forms/checkin.py
@@ -28,7 +28,7 @@ YEARS = [x + 1 for x in range(y - 10, y)]
def get_checkin_locations(user):
"""Return possible checkin location choices for this user."""
from servo.models import User
- if user.is_authenticated():
+ if user.is_authenticated:
return user.locations.enabled()
else:
user_id = Configuration.conf('checkin_user')
@@ -196,7 +196,7 @@ class CustomerForm(forms.Form):
self.fields['checkout_location'].queryset = locations
self.fields['checkout_location'].initial = location
- if request.user.is_authenticated():
+ if request.user.is_authenticated:
del(self.fields['agree_to_terms'])
self.fields['phone'].widget = SearchFieldInput()