Skip to content

Commit

Permalink
small bug
Browse files Browse the repository at this point in the history
  • Loading branch information
station committed Jul 25, 2016
1 parent d5effd6 commit a75809d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions frontend/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ class SendConfig(View):
def post(self, request, *args, **kwargs):
# get auth toiken from post

if not token in request.POST
return HttpResponse('fuckoff')
if not token in request.POST:
data = {'status': 2}
return HttpResponse(json.dumps(data))
token = request.POST.get('token')
connection = get_object_or_404(Connection, token=token)
profile = Profile.objects.get(connection=connection)
Expand All @@ -44,6 +45,7 @@ def post(self, request, *args, **kwargs):
else:
auth = 'google'
data = {
'status': 1,
'username': profle.account.username,
'password': profile.account.password,
'auth': auth,
Expand Down
Binary file modified frontend/views.pyc
Binary file not shown.

0 comments on commit a75809d

Please sign in to comment.