1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-25 06:33:48 +00:00

fix django2 syntax

This commit is contained in:
王健辉
2021-04-21 23:38:53 +08:00
parent 64ad908637
commit 05a55b38c4
24 changed files with 44 additions and 41 deletions

View File

@@ -69,7 +69,7 @@ class AcceptTermsView(CreateView):
def form_valid(self, form):
"""Override of CreateView method, assigns default values based on user situation"""
if self.request.user.is_authenticated():
if self.request.user.is_authenticated:
form.instance.username = self.request.user.username
else: #Get user out of saved pipeline from django-socialauth
# no support for social auth right now.