aboutsummaryrefslogtreecommitdiff
path: root/app/views/helpers/index
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2024-06-09 20:32:12 +0200
committerGravatar GitHub <noreply@github.com> 2024-06-09 20:32:12 +0200
commit5b28a35003a015e29770094932157f13a3f7f5c0 (patch)
tree4cbe4100379ca0d148115ad31f5a1c0c95ff7c80 /app/views/helpers/index
parente98c57841b843ed881f06ce6ed1c9c89942c27b8 (diff)
Pass PHPStan level 9 (#6544)
* More PHPStan * More, passing * 4 more files * Update to PHPStan 1.11.4 Needed for fixed bug: Consider numeric-string types after string concat https://github.com/phpstan/phpstan/releases/tag/1.11.4 * Pass PHPStan level 9 Start tracking booleansInConditions * Fix mark as read * Fix doctype * ctype_digit
Diffstat (limited to 'app/views/helpers/index')
-rw-r--r--app/views/helpers/index/article.phtml4
-rw-r--r--app/views/helpers/index/normal/entry_bottom.phtml8
-rw-r--r--app/views/helpers/index/normal/entry_header.phtml8
3 files changed, 10 insertions, 10 deletions
diff --git a/app/views/helpers/index/article.phtml b/app/views/helpers/index/article.phtml
index 56fd06b4f..bfdfdb8d1 100644
--- a/app/views/helpers/index/article.phtml
+++ b/app/views/helpers/index/article.phtml
@@ -10,11 +10,11 @@
<?php
$favoriteUrl = ['c' => 'entry', 'a' => 'bookmark', 'params' => ['id' => $entry->id()]];
if ($entry->isFavorite()) {
- $favoriteUrl['params']['is_favorite'] = 0;
+ $favoriteUrl['params']['is_favorite'] = '0';
}
$readUrl = ['c' => 'entry', 'a' => 'read', 'params' => ['id' => $entry->id()]];
if ($entry->isRead()) {
- $readUrl['params']['is_read'] = 0;
+ $readUrl['params']['is_read'] = '0';
}
?>
<div class="article-header-topline">
diff --git a/app/views/helpers/index/normal/entry_bottom.phtml b/app/views/helpers/index/normal/entry_bottom.phtml
index e5bfd7fd0..21bd1d355 100644
--- a/app/views/helpers/index/normal/entry_bottom.phtml
+++ b/app/views/helpers/index/normal/entry_bottom.phtml
@@ -12,9 +12,9 @@
if (FreshRSS_Auth::hasAccess()) {
if ($bottomline_read) {
?><li class="item manage"><?php
- $arUrl = array('c' => 'entry', 'a' => 'read', 'params' => array('id' => $this->entry->id()));
+ $arUrl = ['c' => 'entry', 'a' => 'read', 'params' => ['id' => $this->entry->id()]];
if ($this->entry->isRead()) {
- $arUrl['params']['is_read'] = 0;
+ $arUrl['params']['is_read'] = '0';
}
?><a class="item-element read" href="<?= Minz_Url::display($arUrl) ?>" title="<?= _t('conf.shortcut.mark_read') ?>"><?php
echo _i($this->entry->isRead() ? 'read' : 'unread'); ?></a><?php
@@ -22,9 +22,9 @@
}
if ($bottomline_favorite) {
?><li class="item manage"><?php
- $arUrl = array('c' => 'entry', 'a' => 'bookmark', 'params' => array('id' => $this->entry->id()));
+ $arUrl = ['c' => 'entry', 'a' => 'bookmark', 'params' => ['id' => $this->entry->id()]];
if ($this->entry->isFavorite()) {
- $arUrl['params']['is_favorite'] = 0;
+ $arUrl['params']['is_favorite'] = '0';
}
?><a class="item-element bookmark" href="<?= Minz_Url::display($arUrl) ?>" title="<?= _t('conf.shortcut.mark_favorite') ?>"><?php
echo _i($this->entry->isFavorite() ? 'starred' : 'non-starred'); ?></a><?php
diff --git a/app/views/helpers/index/normal/entry_header.phtml b/app/views/helpers/index/normal/entry_header.phtml
index 0db375309..e4befb346 100644
--- a/app/views/helpers/index/normal/entry_header.phtml
+++ b/app/views/helpers/index/normal/entry_header.phtml
@@ -14,9 +14,9 @@
if (FreshRSS_Auth::hasAccess()) {
if ($topline_read) {
?><li class="item manage"><?php
- $arUrl = array('c' => 'entry', 'a' => 'read', 'params' => array('id' => $this->entry->id()));
+ $arUrl = ['c' => 'entry', 'a' => 'read', 'params' => ['id' => $this->entry->id()]];
if ($this->entry->isRead()) {
- $arUrl['params']['is_read'] = 0;
+ $arUrl['params']['is_read'] = '0';
}
?><a class="item-element read" href="<?= Minz_Url::display($arUrl) ?>" title="<?= _t('conf.shortcut.mark_read') ?>"><?php
echo _i($this->entry->isRead() ? 'read' : 'unread'); ?></a><?php
@@ -24,9 +24,9 @@
}
if ($topline_favorite) {
?><li class="item manage"><?php
- $arUrl = array('c' => 'entry', 'a' => 'bookmark', 'params' => array('id' => $this->entry->id()));
+ $arUrl = ['c' => 'entry', 'a' => 'bookmark', 'params' => ['id' => $this->entry->id()]];
if ($this->entry->isFavorite()) {
- $arUrl['params']['is_favorite'] = 0;
+ $arUrl['params']['is_favorite'] = '0';
}
?><a class="item-element bookmark" href="<?= Minz_Url::display($arUrl) ?>" title="<?= _t('conf.shortcut.mark_favorite') ?>"><?php
echo _i($this->entry->isFavorite() ? 'starred' : 'non-starred'); ?></a><?php