busao
    Preparing search index...

    Function handleAdminCancel

    • Handles the cancellation of a single trip by ID.

      Parameters

      • i18n: i18n

        The internationalisation object.

      • request: BunRequest

        The request to the associated endpoint.

      • database: BunSQLiteDatabase

        The project's database.

      • id: string

        The ID of the trip.

      Returns Promise<Response>

      • An "Unauthorized" page in case the admin is unauthenticated.
      • An error message in case something goes wrong with the cancellation process.
      • A request to remove the table row associated with the ID.