<?php
/**
- * @copyright Copyright (C) 2010-2022, the Friendica project
+ * @copyright Copyright (C) 2010-2023, the Friendica project
*
* @license GNU AGPL version 3 or any later version
*
*
* @see L10n::tt()
*/
- protected function tt(string $singular, string $plurarl, int $count): string
+ protected function tt(string $singular, string $plural, int $count): string
{
- return $this->l10n->tt($singular, $plurarl, $count);
+ return $this->l10n->tt($singular, $plural, $count);
}
/**
$this->response->addContent($arr['content']);
$this->response->addContent($this->content($request));
} catch (HTTPException $e) {
+ // In case of System::externalRedirects(), we don't want to prettyprint the exception
+ // just redirect to the new location
+ if (($e instanceof HTTPException\FoundException) ||
+ ($e instanceof HTTPException\MovedPermanentlyException) ||
+ ($e instanceof HTTPException\TemporaryRedirectException)) {
+ throw $e;
+ }
+
+ $this->response->setStatus($e->getCode(), $e->getMessage());
$this->response->addContent($httpException->content($e));
} finally {
$this->profiler->set(microtime(true) - $timestamp, 'content');