defaultShortCodesLength = $defaultShortCodesLength; } public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface { $body = $request->getParsedBody(); if (! isset($body[ShortUrlMetaInputFilter::SHORT_CODE_LENGTH])) { $body[ShortUrlMetaInputFilter::SHORT_CODE_LENGTH] = $this->defaultShortCodesLength; } return $handler->handle($request->withParsedBody($body)); } }