notFound method

Future<void> notFound({
  1. Object? data,
})

Implementation

Future<void> notFound({
  Object? data,
}) async {
  /// append the data to the response
  await json({
    'status_code': io.HttpStatus.notFound,
    'message': 'Not found',
    if (data != null) 'data': data,
  }, statusCode: HttpStatus.notFound);
}