mirror of
https://github.com/optim-enterprises-bv/databunker.git
synced 2025-11-07 13:27:54 +00:00
fix bug in session code
This commit is contained in:
@@ -53,12 +53,7 @@ func (e mainEnv) createSession(w http.ResponseWriter, r *http.Request, ps httpro
|
|||||||
userTOKEN = userBson["token"].(string)
|
userTOKEN = userBson["token"].(string)
|
||||||
event.Record = userTOKEN
|
event.Record = userTOKEN
|
||||||
}
|
}
|
||||||
sessionUUID, err := uuid.GenerateUUID()
|
session, err := e.db.createSessionRecord(session, userTOKEN, expiration, parsedData.jsonData)
|
||||||
if err != nil {
|
|
||||||
returnError(w, r, "internal error", 405, err, event)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
sessionID, err := e.db.createSessionRecord(sessionUUID, userTOKEN, expiration, parsedData.jsonData)
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
returnError(w, r, "internal error", 405, err, event)
|
returnError(w, r, "internal error", 405, err, event)
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user