mirror of
https://github.com/ad-aures/castopod.git
synced 2026-04-11 10:46:43 +02:00
refactor: update code base to php 8 and set phpstan lvl to 6
This commit is contained in:
parent
4a33c50fb6
commit
6b74a9e98a
124 changed files with 1810 additions and 2157 deletions
|
|
@ -24,7 +24,7 @@ class AnalyticsController extends Controller
|
|||
*/
|
||||
protected $methodName;
|
||||
|
||||
public function _remap($method, ...$params)
|
||||
public function _remap(string $method, string ...$params): mixed
|
||||
{
|
||||
if (!isset($params[1])) {
|
||||
throw PageNotFoundException::forPageNotFound();
|
||||
|
|
@ -39,11 +39,11 @@ class AnalyticsController extends Controller
|
|||
);
|
||||
}
|
||||
|
||||
public function getData($podcastId, $episodeId): ResponseInterface
|
||||
public function getData(int $podcastId, int $episodeId): ResponseInterface
|
||||
{
|
||||
$analytics_model = new $this->className();
|
||||
$methodName = $this->methodName;
|
||||
if ($episodeId) {
|
||||
if ($episodeId !== 0) {
|
||||
return $this->response->setJSON(
|
||||
$analytics_model->$methodName($podcastId, $episodeId),
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue