mirror of
https://github.com/getgrav/grav.git
synced 2026-07-19 21:41:14 +02:00
Use strict boolean compare
This commit is contained in:
@@ -283,7 +283,7 @@ class Validation
|
||||
|
||||
protected static function filterFile($value, array $params, array $field)
|
||||
{
|
||||
if (isset($field['multiple']) && $field['multiple'] == true) {
|
||||
if (isset($field['multiple']) && $field['multiple'] === true) {
|
||||
return (array) $value;
|
||||
}
|
||||
|
||||
|
||||
@@ -318,7 +318,7 @@ class Grav extends Container
|
||||
$code = $matches[2];
|
||||
}
|
||||
|
||||
if ($code == null) {
|
||||
if ($code === null) {
|
||||
$code = $this['config']->get('system.pages.redirect_default_code', 301);
|
||||
}
|
||||
|
||||
|
||||
@@ -528,7 +528,7 @@ class Page
|
||||
|
||||
|
||||
// if no cached-content run everything
|
||||
if ($this->content === false || $cache_enable == false) {
|
||||
if ($this->content === false || $cache_enable === false) {
|
||||
$this->content = $this->raw_content;
|
||||
self::getGrav()->fireEvent('onPageContentRaw', new Event(['page' => $this]));
|
||||
|
||||
@@ -1881,7 +1881,7 @@ class Page
|
||||
|
||||
while (true) {
|
||||
$theParent = $topParent->parent();
|
||||
if ($theParent != null && $theParent->parent() !== null) {
|
||||
if ($theParent !== null && $theParent->parent() !== null) {
|
||||
$topParent = $theParent;
|
||||
} else {
|
||||
break;
|
||||
|
||||
@@ -258,7 +258,7 @@ class Uri
|
||||
$language = $grav['language'];
|
||||
|
||||
// add the port to the base for non-standard ports
|
||||
if ($config->get('system.reverse_proxy_setup') == false && $this->port != '80' && $this->port != '443') {
|
||||
if ($config->get('system.reverse_proxy_setup') === false && $this->port != '80' && $this->port != '443') {
|
||||
$this->base .= ":" . $this->port;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user