diff options
Diffstat (limited to 'modern.go')
| -rw-r--r-- | modern.go | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -83,7 +83,12 @@ func (store *SqlStore) AuthGetSession(r *http.Request) ApiResponse { var response struct { Session *Session `json:"session"` } - session := NewSession("thibauthorel", r.FormValue("api_key"), "2.0") + session := &Session{ + User: "thibauthorel", + Client: r.FormValue("api_key"), + Protocol: "2.0", + Key: randomToken(16), + } store.PutSession(session) response.Session = session return response |
