adding garminlog.log to gitignore
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -2,6 +2,7 @@
|
|||||||
/django_cache/
|
/django_cache/
|
||||||
testcert.crt
|
testcert.crt
|
||||||
testcert.key
|
testcert.key
|
||||||
|
garminlog.log
|
||||||
|
|
||||||
# Compiled python modules.
|
# Compiled python modules.
|
||||||
*.pyc
|
*.pyc
|
||||||
|
|||||||
@@ -1014,6 +1014,13 @@ def garmin_summaries_view(request):
|
|||||||
if request.method != 'POST':
|
if request.method != 'POST':
|
||||||
return HttpResponse(status=200)
|
return HttpResponse(status=200)
|
||||||
|
|
||||||
|
t = time.localtime()
|
||||||
|
timestamp = time.strftime('%b-%d-%Y_%H%M', t)
|
||||||
|
with open('garminlog.log','a') as f:
|
||||||
|
f.write('\n')
|
||||||
|
f.write(timestamp)
|
||||||
|
f.write(' ')
|
||||||
|
f.write(str(request.body))
|
||||||
# POST request
|
# POST request
|
||||||
data = json.loads(request.body)
|
data = json.loads(request.body)
|
||||||
activities = data['activities']
|
activities = data['activities']
|
||||||
@@ -1029,6 +1036,14 @@ def garmin_deregistration_view(request):
|
|||||||
if request.method != 'POST':
|
if request.method != 'POST':
|
||||||
return HttpResponse(status=200)
|
return HttpResponse(status=200)
|
||||||
|
|
||||||
|
t = time.localtime()
|
||||||
|
timestamp = time.strftime('%b-%d-%Y_%H%M', t)
|
||||||
|
with open('garminlog.log','a') as f:
|
||||||
|
f.write('\n')
|
||||||
|
f.write(timestamp)
|
||||||
|
f.write(' ')
|
||||||
|
f.write(str(request.body))
|
||||||
|
|
||||||
data = json.loads(request.body)
|
data = json.loads(request.body)
|
||||||
try:
|
try:
|
||||||
garmintoken = data['userAccessToken']
|
garmintoken = data['userAccessToken']
|
||||||
|
|||||||
Reference in New Issue
Block a user