stop method

Future stop({
  1. bool force = true,
})

Stops the server and closes the database connection.

The force parameter specifies whether to forcefully close the server.

Implementation

Future stop({bool force = true}) async {
  if (server != null) {
    await server!.close(force: force);
  }

  await db.close();
  server = null;
}