diff options
| author | 2021-12-31 17:00:51 +0100 | |
|---|---|---|
| committer | 2021-12-31 17:00:51 +0100 | |
| commit | 77e9877316fcfacb26799afdf32d94c8411da80e (patch) | |
| tree | 7fd9c85bf4854054be6536c14d120bc8b790debe /app/views | |
| parent | 09c84fb3bc44bf8e45619c27acc15b967aea14ce (diff) | |
Add PHPStan (#4021)
* Add PHPStan
#fix https://github.com/FreshRSS/FreshRSS/issues/4016
https://phpstan.org/
```sh
composer run-script phpstan
```
* More fixes
* Fix global variables
* Add .phtml
* Fix merge
https://github.com/FreshRSS/FreshRSS/pull/4090
* Fix more warnings
* Fix view errors and enable in CI
* ReturnTypeWillChange
* Dynamic view type
* Fix Minz static/self bug
Diffstat (limited to 'app/views')
60 files changed, 157 insertions, 45 deletions
diff --git a/app/views/auth/formLogin.phtml b/app/views/auth/formLogin.phtml index e61aaf922..e218d089d 100644 --- a/app/views/auth/formLogin.phtml +++ b/app/views/auth/formLogin.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <main class="prompt"> <h1><?= _t('gen.auth.login') ?></h1> diff --git a/app/views/auth/index.phtml b/app/views/auth/index.phtml index 9c9cd1eaa..a18ab49e2 100644 --- a/app/views/auth/index.phtml +++ b/app/views/auth/index.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/auth/register.phtml b/app/views/auth/register.phtml index 7eb2af12f..a56eff3ee 100644 --- a/app/views/auth/register.phtml +++ b/app/views/auth/register.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <main class="prompt"> <h1><?= _t('gen.auth.registration') ?></h1> diff --git a/app/views/configure/archiving.phtml b/app/views/configure/archiving.phtml index fd56c8dde..47281e2f1 100644 --- a/app/views/configure/archiving.phtml +++ b/app/views/configure/archiving.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> @@ -7,7 +10,7 @@ <h1><?= _t('conf.archiving') ?></h1> <p class="help"><?= _i('help') ?> <?= _t('conf.archiving.help') ?></p> - + <form method="post" action="<?= _url('configure', 'archiving') ?>"> <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> diff --git a/app/views/configure/display.phtml b/app/views/configure/display.phtml index dfb377893..e3e18f5a0 100644 --- a/app/views/configure/display.phtml +++ b/app/views/configure/display.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> @@ -6,7 +9,7 @@ </div> <h1><?= _t('conf.display') ?></h1> - + <form method="post" action="<?= _url('configure', 'display') ?>"> <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> diff --git a/app/views/configure/integration.phtml b/app/views/configure/integration.phtml index 9bd7257ee..c8d299f44 100644 --- a/app/views/configure/integration.phtml +++ b/app/views/configure/integration.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> @@ -24,7 +27,7 @@ <a target="_blank" rel="noreferrer" class="btn" title="<?= _t('conf.sharing.more_information') ?>" href="##help##"><?= _i('help') ?></a> </div></div>' class="draggableList"> <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> - + <?php foreach (FreshRSS_Context::$user_conf->sharing as $key => $share_options) { $share = FreshRSS_Share::get($share_options['type']); diff --git a/app/views/configure/queries.phtml b/app/views/configure/queries.phtml index 6de606639..3f15f299b 100644 --- a/app/views/configure/queries.phtml +++ b/app/views/configure/queries.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/configure/query.phtml b/app/views/configure/query.phtml index 6f38d9efb..316583bac 100644 --- a/app/views/configure/query.phtml +++ b/app/views/configure/query.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php if ($this->query) { diff --git a/app/views/configure/reading.phtml b/app/views/configure/reading.phtml index da4e104a4..c021132aa 100644 --- a/app/views/configure/reading.phtml +++ b/app/views/configure/reading.phtml @@ -1,15 +1,18 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> <a class="link-back" href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a> </div> - + <h1><?= _t('conf.reading') ?></h1> <form method="post" action="<?= _url('configure', 'reading') ?>"> <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> - + <div class="form-group"> <label class="group-name" for="posts_per_page"><?= _t('conf.reading.articles_per_page') ?></label> <div class="group-controls"> diff --git a/app/views/configure/shortcut.phtml b/app/views/configure/shortcut.phtml index ee671740e..ca4a42c86 100644 --- a/app/views/configure/shortcut.phtml +++ b/app/views/configure/shortcut.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> @@ -25,7 +28,7 @@ <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> <noscript><p class="alert alert-error"><?= _t('conf.shortcut.javascript') ?></p></noscript> - + <fieldset> <legend><?= _t('conf.shortcut.views') ?></legend> diff --git a/app/views/configure/system.phtml b/app/views/configure/system.phtml index fa9e11ce2..7f355d156 100644 --- a/app/views/configure/system.phtml +++ b/app/views/configure/system.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/entry/bookmark.phtml b/app/views/entry/bookmark.phtml index e842f7465..bab937f6c 100755 --- a/app/views/entry/bookmark.phtml +++ b/app/views/entry/bookmark.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php header('Content-Type: application/json; charset=UTF-8'); diff --git a/app/views/entry/read.phtml b/app/views/entry/read.phtml index 44193da9c..0d87bf583 100755 --- a/app/views/entry/read.phtml +++ b/app/views/entry/read.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php header('Content-Type: application/json; charset=UTF-8'); diff --git a/app/views/error/index.phtml b/app/views/error/index.phtml index 98473cc83..abebc8332 100644 --- a/app/views/error/index.phtml +++ b/app/views/error/index.phtml @@ -1,11 +1,12 @@ +<?php /** @var FreshRSS_View $this */ ?> <main class="post"> <div class="alert alert-error"> <h1 class="alert-head"><?= $this->code ?></h1> <p> <?= htmlspecialchars($this->errorMessage, ENT_NOQUOTES, 'UTF-8') ?> </p> - <p> - <?php if (FreshRSS_Auth::hasAccess()) {?> + <p> + <?php if (FreshRSS_Auth::hasAccess()) {?> <a href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a> <?php } else { ?> <a href="<?= _url('auth', 'login') ?>"><?= _t('gen.auth.login') ?></a> diff --git a/app/views/extension/configure.phtml b/app/views/extension/configure.phtml index 8933eeae5..27946e202 100644 --- a/app/views/extension/configure.phtml +++ b/app/views/extension/configure.phtml @@ -1,3 +1,3 @@ <?php - +/** @var FreshRSS_View $this */ $this->renderHelper('extension/configure'); diff --git a/app/views/extension/index.phtml b/app/views/extension/index.phtml index b9ae7a92c..ba789bebd 100644 --- a/app/views/extension/index.phtml +++ b/app/views/extension/index.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/feed/add.phtml b/app/views/feed/add.phtml index 55cfe0845..fb3d89ef5 100644 --- a/app/views/feed/add.phtml +++ b/app/views/feed/add.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php if ($this->feed) { ?> <main class="post"> <h1><?= _t('sub.feed.add') ?></h1> diff --git a/app/views/feed/contentSelectorPreview.phtml b/app/views/feed/contentSelectorPreview.phtml index 3bb27859a..7ff251e38 100644 --- a/app/views/feed/contentSelectorPreview.phtml +++ b/app/views/feed/contentSelectorPreview.phtml @@ -1,8 +1,11 @@ -<?php FreshRSS::preLayout(); ?> +<?php + /** @var FreshRSS_View $this */ + FreshRSS::preLayout(); +?> <!DOCTYPE html> <html class="preview_background" lang="<?= FreshRSS_Context::$user_conf->language ?>" xml:lang="<?= FreshRSS_Context::$user_conf->language ?>"> <head> - <?= self::headStyle() ?> + <?= FreshRSS_View::headStyle() ?> <script src="<?= Minz_Url::display('/scripts/preview.js?' . @filemtime(PUBLIC_PATH . '/scripts/preview.js')) ?>"></script> </head> <body class="preview_background"> diff --git a/app/views/helpers/category/update.phtml b/app/views/helpers/category/update.phtml index 085b49aa6..291dd7fc4 100644 --- a/app/views/helpers/category/update.phtml +++ b/app/views/helpers/category/update.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <div class="post"> <h2><?= $this->category->name() ?></h2> @@ -30,7 +31,7 @@ <div class="group-controls"> <button class="btn btn-important"><?= _t('gen.action.submit') ?></button> <button type="reset" class="btn"><?= _t('gen.action.cancel') ?></button> - + </div> </div> diff --git a/app/views/helpers/configure/query.phtml b/app/views/helpers/configure/query.phtml index a9bf4478d..3dc6c2459 100644 --- a/app/views/helpers/configure/query.phtml +++ b/app/views/helpers/configure/query.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <div class="post"> <h2><?= $this->query->getName() ?></h2> diff --git a/app/views/helpers/export/articles.phtml b/app/views/helpers/export/articles.phtml index 0bbfb86ec..c131b8474 100644 --- a/app/views/helpers/export/articles.phtml +++ b/app/views/helpers/export/articles.phtml @@ -1,4 +1,5 @@ <?php +/** @var FreshRSS_View $this */ $username = Minz_Session::param('currentUser', '_'); $options = JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE; diff --git a/app/views/helpers/export/opml.phtml b/app/views/helpers/export/opml.phtml index edb4d4eda..971dc1445 100644 --- a/app/views/helpers/export/opml.phtml +++ b/app/views/helpers/export/opml.phtml @@ -1,4 +1,5 @@ <?php +/** @var FreshRSS_View $this */ $opml_array = array( 'head' => array( diff --git a/app/views/helpers/extension/configure.phtml b/app/views/helpers/extension/configure.phtml index 4f8c521ae..ea68287b1 100644 --- a/app/views/helpers/extension/configure.phtml +++ b/app/views/helpers/extension/configure.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <div class="post"> <h2> <?= $this->extension->getName() ?> (<?= $this->extension->getVersion() ?>) — diff --git a/app/views/helpers/extension/details.phtml b/app/views/helpers/extension/details.phtml index ed9674e3d..f6b361c6f 100644 --- a/app/views/helpers/extension/details.phtml +++ b/app/views/helpers/extension/details.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <ul class="horizontal-list"> <li class="item"> <?php if ($this->ext_details->getType() === 'user' || FreshRSS_Auth::hasAccess('admin')) { ?> diff --git a/app/views/helpers/feed/update.phtml b/app/views/helpers/feed/update.phtml index 703de3202..949c6492f 100644 --- a/app/views/helpers/feed/update.phtml +++ b/app/views/helpers/feed/update.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <div class="post"> <h1><?= $this->feed->name() ?></h1> diff --git a/app/views/helpers/index/normal/entry_bottom.phtml b/app/views/helpers/index/normal/entry_bottom.phtml index bf1dc7b3d..07e68ed92 100644 --- a/app/views/helpers/index/normal/entry_bottom.phtml +++ b/app/views/helpers/index/normal/entry_bottom.phtml @@ -1,4 +1,5 @@ <?php + /** @var FreshRSS_View $this */ $sharing = array(); if (FreshRSS_Auth::hasAccess()) { $sharing = FreshRSS_Context::$user_conf->sharing; diff --git a/app/views/helpers/index/normal/entry_header.phtml b/app/views/helpers/index/normal/entry_header.phtml index 784a440a0..79e6e4215 100644 --- a/app/views/helpers/index/normal/entry_header.phtml +++ b/app/views/helpers/index/normal/entry_header.phtml @@ -1,4 +1,5 @@ <?php + /** @var FreshRSS_View $this */ $topline_read = FreshRSS_Context::$user_conf->topline_read; $topline_favorite = FreshRSS_Context::$user_conf->topline_favorite; $topline_thumbnail = FreshRSS_Context::$user_conf->topline_thumbnail; diff --git a/app/views/helpers/javascript_vars.phtml b/app/views/helpers/javascript_vars.phtml index 256b6bf5f..3860c6204 100644 --- a/app/views/helpers/javascript_vars.phtml +++ b/app/views/helpers/javascript_vars.phtml @@ -1,4 +1,5 @@ <?php +/** @var FreshRSS_View $this */ $mark = FreshRSS_Context::$user_conf->mark_when; $s = FreshRSS_Context::$user_conf->shortcuts; $extData = Minz_ExtensionManager::callHook('js_vars', []); diff --git a/app/views/helpers/logs_pagination.phtml b/app/views/helpers/logs_pagination.phtml index fa69d0b44..fe6a71a3a 100755 --- a/app/views/helpers/logs_pagination.phtml +++ b/app/views/helpers/logs_pagination.phtml @@ -1,4 +1,5 @@ <?php + /** @var FreshRSS_View $this */ $c = Minz_Request::controllerName(); $a = Minz_Request::actionName(); $params = $_GET; @@ -6,7 +7,10 @@ <?php if ($this->nbPage > 1) { ?> <ul class="pagination"> - <?php $params[$getteur] = 1; ?> + <?php + /** @var int $getteur */ + $params[$getteur] = 1; + ?> <li class="item pager-first"> <?php if ($this->currentPage > 1) { ?> <a href="<?= Minz_Url::display(array('c' => $c, 'a' => $a, 'params' => $params)) ?>">« <?= _t('gen.pagination.first') ?></a> diff --git a/app/views/helpers/pagination.phtml b/app/views/helpers/pagination.phtml index cefa835bd..9b249762c 100755 --- a/app/views/helpers/pagination.phtml +++ b/app/views/helpers/pagination.phtml @@ -1,4 +1,5 @@ <?php + /** @var FreshRSS_View $this */ $url_next = Minz_Request::currentRequest(); $url_next['params']['next'] = FreshRSS_Context::$next_id; $url_next['params']['state'] = FreshRSS_Context::$state; diff --git a/app/views/importExport/export.phtml b/app/views/importExport/export.phtml index 399e72d00..21ed71b2d 100644 --- a/app/views/importExport/export.phtml +++ b/app/views/importExport/export.phtml @@ -1 +1,2 @@ +<?php /** @var FreshRSS_View $this */ ?> <?= $this->content ?> diff --git a/app/views/importExport/index.phtml b/app/views/importExport/index.phtml index 69e10ea27..c5bc97446 100644 --- a/app/views/importExport/index.phtml +++ b/app/views/importExport/index.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post "> <div class="link-back-wrapper"> diff --git a/app/views/index/about.phtml b/app/views/index/about.phtml index cd8cfcade..e25e9a119 100644 --- a/app/views/index/about.phtml +++ b/app/views/index/about.phtml @@ -1,6 +1,9 @@ -<?php if (FreshRSS_Auth::hasAccess()) {?> -<?php $this->partial('aside_configure'); ?> -<?php } ?> +<?php + /** @var FreshRSS_View $this */ + if (FreshRSS_Auth::hasAccess()) { + $this->partial('aside_configure'); + } +?> <main class="post content"> <?php if (FreshRSS_Auth::hasAccess()) {?> diff --git a/app/views/index/global.phtml b/app/views/index/global.phtml index ce1132df5..ff5fceaed 100644 --- a/app/views/index/global.phtml +++ b/app/views/index/global.phtml @@ -1,4 +1,5 @@ <?php + /** @var FreshRSS_View $this */ $this->partial('nav_menu'); $class = ''; diff --git a/app/views/index/logs.phtml b/app/views/index/logs.phtml index bcdc5b073..a8e78810c 100644 --- a/app/views/index/logs.phtml +++ b/app/views/index/logs.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <main class="post content"> <div class="link-back-wrapper"> <a class="link-back" href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a> diff --git a/app/views/index/normal.phtml b/app/views/index/normal.phtml index 4adc7047e..eb388fad3 100644 --- a/app/views/index/normal.phtml +++ b/app/views/index/normal.phtml @@ -1,4 +1,5 @@ <?php +/** @var FreshRSS_View $this */ $this->partial('aside_feed'); $this->partial('nav_menu'); diff --git a/app/views/index/reader.phtml b/app/views/index/reader.phtml index 6b68ea08f..315d7d7aa 100644 --- a/app/views/index/reader.phtml +++ b/app/views/index/reader.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php $this->partial('aside_feed'); $this->partial('nav_menu'); diff --git a/app/views/index/rss.phtml b/app/views/index/rss.phtml index 00be01c28..f0772cc86 100755 --- a/app/views/index/rss.phtml +++ b/app/views/index/rss.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?= '<?xml version="1.0" encoding="UTF-8" ?>'; ?> <rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/"> <channel> diff --git a/app/views/index/tos.phtml b/app/views/index/tos.phtml index f8240ed29..5e7f8ea58 100644 --- a/app/views/index/tos.phtml +++ b/app/views/index/tos.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <main class="post content"> <?php if ($this->can_register) { ?> <a href="<?= _url('auth', 'register') ?>"> diff --git a/app/views/javascript/actualize.phtml b/app/views/javascript/actualize.phtml index 3baabf748..c154137f6 100644 --- a/app/views/javascript/actualize.phtml +++ b/app/views/javascript/actualize.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php $feeds = array(); foreach ($this->feeds as $feed) { diff --git a/app/views/javascript/nbUnreadsPerFeed.phtml b/app/views/javascript/nbUnreadsPerFeed.phtml index ce4db37b7..261f2a179 100644 --- a/app/views/javascript/nbUnreadsPerFeed.phtml +++ b/app/views/javascript/nbUnreadsPerFeed.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php $result = array( 'feeds' => array(), diff --git a/app/views/javascript/nonce.phtml b/app/views/javascript/nonce.phtml index 4ac46c8fc..f565baa85 100644 --- a/app/views/javascript/nonce.phtml +++ b/app/views/javascript/nonce.phtml @@ -1,2 +1,3 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php echo json_encode(array('salt1' => $this->salt1, 'nonce' => $this->nonce)); diff --git a/app/views/stats/idle.phtml b/app/views/stats/idle.phtml index 8efaef5e9..40feb4a03 100644 --- a/app/views/stats/idle.phtml +++ b/app/views/stats/idle.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/stats/index.phtml b/app/views/stats/index.phtml index 26e3f0dbc..2d7e941b6 100644 --- a/app/views/stats/index.phtml +++ b/app/views/stats/index.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/stats/repartition.phtml b/app/views/stats/repartition.phtml index 86cc1b6bc..803d39b8e 100644 --- a/app/views/stats/repartition.phtml +++ b/app/views/stats/repartition.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post "> <div class="link-back-wrapper"> diff --git a/app/views/subscription/add.phtml b/app/views/subscription/add.phtml index 5eff9c5d1..df74b24f2 100644 --- a/app/views/subscription/add.phtml +++ b/app/views/subscription/add.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post drop-section"> <div class="link-back-wrapper"> @@ -25,7 +28,7 @@ <h2><?= _t('sub.title.add_feed') ?></h2> <form id="add_rss" method="post" action="<?= _url('feed', 'add') ?>" autocomplete="off"> - + <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> <div class="form-group"> diff --git a/app/views/subscription/bookmarklet.phtml b/app/views/subscription/bookmarklet.phtml index 90c349c0b..540bf8e52 100644 --- a/app/views/subscription/bookmarklet.phtml +++ b/app/views/subscription/bookmarklet.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/subscription/category.phtml b/app/views/subscription/category.phtml index 38746f23c..90de4e11b 100644 --- a/app/views/subscription/category.phtml +++ b/app/views/subscription/category.phtml @@ -1,5 +1,5 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php - if ($this->category) { $this->renderHelper('category/update'); } diff --git a/app/views/subscription/feed.phtml b/app/views/subscription/feed.phtml index 1a167777f..efe75068d 100644 --- a/app/views/subscription/feed.phtml +++ b/app/views/subscription/feed.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php if (!Minz_Request::param('ajax')) { diff --git a/app/views/subscription/index.phtml b/app/views/subscription/index.phtml index a8bc9ae27..e16d6ad95 100644 --- a/app/views/subscription/index.phtml +++ b/app/views/subscription/index.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post drop-section"> <div class="link-back-wrapper"> @@ -14,7 +17,7 @@ <p class="alert alert-warn"> <?= _t('sub.feed.showing.error') ?> </p> - + <?php endif; ?> <?php if (!$this->onlyFeedsWithError && $this->signalError){ ?> diff --git a/app/views/tag/getTagsForEntry.phtml b/app/views/tag/getTagsForEntry.phtml index 76b2ada4e..9125ae84b 100644 --- a/app/views/tag/getTagsForEntry.phtml +++ b/app/views/tag/getTagsForEntry.phtml @@ -1,2 +1,3 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php echo json_encode($this->tags); diff --git a/app/views/tag/index.phtml b/app/views/tag/index.phtml index e538f96e2..c80e0c209 100644 --- a/app/views/tag/index.phtml +++ b/app/views/tag/index.phtml @@ -1,10 +1,13 @@ -<?php $this->partial('aside_subscription'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_subscription'); +?> <main class="post"> <div class="link-back-wrapper"> <a class="link-back" href="<?= _url('index', 'index') ?>"><?= _t('gen.action.back_to_rss_feeds') ?></a> </div> - + <h1><?= _t('sub.menu.label_management') ?></h1> <h2><?= _t('sub.title.add_label') ?></h2> diff --git a/app/views/update/apply.phtml b/app/views/update/apply.phtml index b96b3f07f..077eb2184 100644 --- a/app/views/update/apply.phtml +++ b/app/views/update/apply.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> @@ -7,5 +10,8 @@ <h1><?= _t('admin.update') ?></h1> - <?php ask_info_update(); ?> + <?php + // @phpstan-ignore-next-line + ask_info_update(); + ?> </main> diff --git a/app/views/update/checkInstall.phtml b/app/views/update/checkInstall.phtml index 0e324de4a..393a9fdee 100644 --- a/app/views/update/checkInstall.phtml +++ b/app/views/update/checkInstall.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/update/index.phtml b/app/views/update/index.phtml index 359e35bea..d2838a5a5 100644 --- a/app/views/update/index.phtml +++ b/app/views/update/index.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> diff --git a/app/views/user/details.phtml b/app/views/user/details.phtml index 6de1a6097..af388c713 100644 --- a/app/views/user/details.phtml +++ b/app/views/user/details.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <?php $isDefault = $this->details['is_default']; ?> <?php $isAdmin = $this->details['is_admin']; ?> diff --git a/app/views/user/manage.phtml b/app/views/user/manage.phtml index ae66e4b2f..0d01d33d7 100644 --- a/app/views/user/manage.phtml +++ b/app/views/user/manage.phtml @@ -1,4 +1,7 @@ -<?php $this->partial('aside_configure'); ?> +<?php + /** @var FreshRSS_View $this */ + $this->partial('aside_configure'); +?> <main class="post"> <div class="link-back-wrapper"> @@ -12,7 +15,7 @@ <input type="hidden" name="originController" value="<?= Minz_Request::controllerName() ?>" /> <input type="hidden" name="originAction" value="<?= Minz_Request::actionName() ?>" /> - + <div class="form-group"> <label class="group-name" for="new_user_language"><?= _t('admin.user.language') ?></label> diff --git a/app/views/user/profile.phtml b/app/views/user/profile.phtml index 39b138c78..99ebcb326 100644 --- a/app/views/user/profile.phtml +++ b/app/views/user/profile.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?php if (!$this->disable_aside) { $this->partial('aside_configure'); @@ -103,7 +104,7 @@ <form id="crypto-form" method="post" action="<?= _url('user', 'delete') ?>"> <input type="hidden" name="_csrf" value="<?= FreshRSS_Auth::csrfToken() ?>" /> - + <p class="alert alert-warn"><span class="alert-head"><?= _t('gen.short.attention') ?></span> <?= _t('conf.profile.delete.warn') ?></p> <div class="form-group"> diff --git a/app/views/user/validateEmail.phtml b/app/views/user/validateEmail.phtml index 31c19f738..bd36510dd 100644 --- a/app/views/user/validateEmail.phtml +++ b/app/views/user/validateEmail.phtml @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <main class="post"> <p> <?= _t('user.email.validation.need_to', FreshRSS_Context::$system_conf->title) ?> diff --git a/app/views/user_mailer/email_need_validation.txt.php b/app/views/user_mailer/email_need_validation.txt.php index c1f4d9911..2785911bf 100644 --- a/app/views/user_mailer/email_need_validation.txt.php +++ b/app/views/user_mailer/email_need_validation.txt.php @@ -1,3 +1,4 @@ +<?php /** @var FreshRSS_View $this */ ?> <?= _t('user.mailer.email_need_validation.welcome', $this->username) ?> <?= _t('user.mailer.email_need_validation.body', $this->site_title) ?> |
