For requests with an `id`, you can auto-load the entity. * Errors terminate the request, success sets `req[id] = data`.
(req, id, callback)
| 10 | * Errors terminate the request, success sets `req[id] = data`. |
| 11 | */ |
| 12 | load(req, id, callback) { |
| 13 | var facet = facets.find( facet => facet.id===id ), |
| 14 | err = facet ? null : 'Not found'; |
| 15 | callback(err, user); |
| 16 | }, |
| 17 | |
| 18 | /** GET / - List all entities */ |
| 19 | index({ params }, res) { |
nothing calls this directly
no outgoing calls
no test coverage detected