docs: function (error, data) {
        const hookArgs = args.concat([ params, callback ]);
  
        if (error) {
          debug(`Error in REST handler: \`${error.message || error}\``);
          res.hook = hookObject(method, 'error', hookArgs);
          return next(error);
        }
  
        res.data = data;
        res.hook = hookObject(method, 'after', hookArgs);
  
        if (!data) {
          debug(`No content returned for '${req.url}'`);
          res.status(statusCodes.noContent);
        } else if (method === 'create') {
          res.status(statusCodes.created);
        }
  
        return next();
      }