diff options
| author | 2024-09-11 17:14:53 +0200 | |
|---|---|---|
| committer | 2024-09-11 17:14:53 +0200 | |
| commit | dfac9f5813df7d4c7c812c381364c8898333f559 (patch) | |
| tree | 978496d0a8d8b0d6b5dbe836c6829296133b337c /app/views/configure | |
| parent | 31c8846791d4b5316fbc790202f79545c012f9c2 (diff) | |
PHPStan booleansInConditions (#6793)
* PHPStan booleansInConditions
* Uniformisation
Diffstat (limited to 'app/views/configure')
| -rw-r--r-- | app/views/configure/archiving.phtml | 4 | ||||
| -rw-r--r-- | app/views/configure/queries.phtml | 4 | ||||
| -rw-r--r-- | app/views/configure/query.phtml | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/app/views/configure/archiving.phtml b/app/views/configure/archiving.phtml index 86b8246e3..7ab8a2d9a 100644 --- a/app/views/configure/archiving.phtml +++ b/app/views/configure/archiving.phtml @@ -59,8 +59,8 @@ <div class="group-controls"> <label class="checkbox" for="enable_keep_period"> <input type="checkbox" name="enable_keep_period" id="enable_keep_period" value="1"<?= - FreshRSS_Context::userConf()->volatile['enable_keep_period'] ? ' checked="checked"' : '' ?> - data-leave-validation="<?= FreshRSS_Context::userConf()->volatile['enable_keep_period'] ? 1 : 0 ?>"/> + empty(FreshRSS_Context::userConf()->volatile['enable_keep_period']) ? '' : ' checked="checked"' ?> + data-leave-validation="<?= empty(FreshRSS_Context::userConf()->volatile['enable_keep_period']) ? 0 : 1 ?>"/> <?= _t('conf.archiving.keep_period') ?> <input type="number" id="keep_period_count" name="keep_period_count" min="0" value="<?= FreshRSS_Context::userConf()->volatile['keep_period_count'] ?>" data-leave-validation="<?= FreshRSS_Context::userConf()->volatile['keep_period_count'] ?>"/> diff --git a/app/views/configure/queries.phtml b/app/views/configure/queries.phtml index 26534307e..d085016fb 100644 --- a/app/views/configure/queries.phtml +++ b/app/views/configure/queries.phtml @@ -49,11 +49,11 @@ <li class="item"><?= _t('conf.query.state_' . $query->getState()) ?></li> <?php } ?> - <?php if ($query->getOrder()) { ?> + <?php if ($query->getOrder() !== '') { ?> <li class="item"><?= _t('conf.query.order_' . strtolower($query->getOrder())) ?></li> <?php } ?> - <?php if ($query->getGet()) { ?> + <?php if ($query->getGet() !== '') { ?> <li class="item"><?= _t('conf.query.get_' . $query->getGetType(), $query->getGetName()) ?></li> <?php } ?> <?php } ?> diff --git a/app/views/configure/query.phtml b/app/views/configure/query.phtml index e45820fbc..51051b98a 100644 --- a/app/views/configure/query.phtml +++ b/app/views/configure/query.phtml @@ -5,6 +5,6 @@ declare(strict_types=1); if (!Minz_Request::paramBoolean('ajax')) { $this->partial('aside_configure'); } -if ($this->query) { +if ($this->query !== null) { $this->renderHelper('configure/query'); } |
