1
0
mirror of https://github.com/LukePeters/flask-mongo-api-boilerplate.git synced 2026-05-16 15:16:31 +09:00

Switched to isodate vs epoch for all timestamps. Utilzing Python's uuid for random IDs now. Improved setup script to install Pipenv if it isn't already installed.

This commit is contained in:
Luke Peters
2019-03-15 17:28:38 -04:00
parent 6477bdcac4
commit 0f360be43c
6 changed files with 26 additions and 15 deletions

View File

@@ -13,12 +13,11 @@ class User:
"id": tools.randID(),
"ip_addresses": [request.remote_addr],
"acct_active": True,
"date_created": tools.nowEpoch(),
"last_login": tools.nowEpoch(),
"date_created": tools.nowDatetimeUTC(),
"last_login": tools.nowDatetimeUTC(),
"first_name": "",
"last_name": "",
"email": "",
"plan": "free"
"email": ""
}
def get(self):
@@ -66,7 +65,7 @@ class User:
app.db.users.update({ "id": user["id"] }, { "$set": {
"refresh_token": refresh_token,
"last_login": tools.nowEpoch()
"last_login": tools.nowDatetimeUTC()
} })
resp = tools.JsonResp({