mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
Reverse logic operators.
This commit is contained in:
@@ -154,7 +154,7 @@ trait UserNavigation
|
||||
$uri = (string)session($identifier);
|
||||
Log::debug(sprintf('The URI is %s', $uri));
|
||||
|
||||
if (!(false === strpos($uri, 'jscript'))) {
|
||||
if (false !== strpos($uri, 'jscript')) {
|
||||
$uri = $this->redirectUri; // @codeCoverageIgnore
|
||||
Log::debug(sprintf('URI is now %s (uri contains jscript)', $uri));
|
||||
}
|
||||
|
@@ -531,21 +531,21 @@ class Steam
|
||||
{
|
||||
$string = strtolower($string);
|
||||
|
||||
if (!(false === stripos($string, 'k'))) {
|
||||
if (false !== stripos($string, 'k')) {
|
||||
// has a K in it, remove the K and multiply by 1024.
|
||||
$bytes = bcmul(rtrim($string, 'kK'), '1024');
|
||||
|
||||
return (int)$bytes;
|
||||
}
|
||||
|
||||
if (!(false === stripos($string, 'm'))) {
|
||||
if (false !== stripos($string, 'm')) {
|
||||
// has a M in it, remove the M and multiply by 1048576.
|
||||
$bytes = bcmul(rtrim($string, 'mM'), '1048576');
|
||||
|
||||
return (int)$bytes;
|
||||
}
|
||||
|
||||
if (!(false === stripos($string, 'g'))) {
|
||||
if (false !== stripos($string, 'g')) {
|
||||
// has a G in it, remove the G and multiply by (1024)^3.
|
||||
$bytes = bcmul(rtrim($string, 'gG'), '1073741824');
|
||||
|
||||
|
@@ -95,7 +95,7 @@ class General extends AbstractExtension
|
||||
$args = func_get_args();
|
||||
$route = $args[0]; // name of the route.
|
||||
$name = Route::getCurrentRoute()->getName() ?? '';
|
||||
if (!(false === strpos($name, $route))) {
|
||||
if (false !== strpos($name, $route)) {
|
||||
return 'active';
|
||||
}
|
||||
|
||||
@@ -118,7 +118,7 @@ class General extends AbstractExtension
|
||||
$args = func_get_args();
|
||||
$route = $args[0]; // name of the route.
|
||||
$name = Route::getCurrentRoute()->getName() ?? '';
|
||||
if (!(false === strpos($name, $route))) {
|
||||
if (false !== strpos($name, $route)) {
|
||||
return 'menu-open';
|
||||
}
|
||||
|
||||
@@ -141,7 +141,7 @@ class General extends AbstractExtension
|
||||
[, $route, $objectType] = func_get_args();
|
||||
$activeObjectType = $context['objectType'] ?? false;
|
||||
|
||||
if ($objectType === $activeObjectType && !(false === stripos(Route::getCurrentRoute()->getName(), $route))) {
|
||||
if ($objectType === $activeObjectType && false !== stripos(Route::getCurrentRoute()->getName(), $route)) {
|
||||
return 'active';
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user