Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/diegohaz/rest
/ login
Function
login
generators/app/templates/api/auth/controller.js:4–8 ·
view source on GitHub ↗
({ user }, res, next)
Source
from the content-addressed store, hash-verified
2
import
{ success } from
'../../services/response/'
3
4
export
const
login = ({ user }, res, next) =>
5
sign(user.id)
6
.then((token) => ({ token, user: user.view(true) }))
7
.then(success(res, 201))
8
.catch(next)
Callers
nothing calls this directly
Calls
2
sign
Function · 0.90
success
Function · 0.90
Tested by
no test coverage detected