You are here

public function BatApiMiddleware::handle in Booking and Availability Management API 8

File

src/StackMiddleware/BatApiMiddleware.php, line 37
Contains \Drupal\bat_api\StackMiddleware\BatApiMiddleware.php

Class

BatApiMiddleware
Provides a HTTP middleware.

Namespace

Drupal\bat_api\StackMiddleware

Code

public function handle(Request $request, $type = self::MASTER_REQUEST, $catch = TRUE) {
  if ($format = $request
    ->get('_format')) {
    $request
      ->setRequestFormat($format);
  }
  return $this->httpKernel
    ->handle($request, $type, $catch);
}