You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Info
I have been trying for over a week to trace a new site's "Network connection Error" from going down overnight. No errors in logs so added "strict_types=1" to all PHP app and system PHP files, also set .env -> CI_ENVIRONMENT = development and eventually managed to get some errors reported.
Describe the bug
incorrect type being passed.
CodeIgniter 4 version
CI_VERSION 4.1.1
Affected module(s)
File: ./system/Validation/FormatRules.php
[code]
public function valid_ip(string $ip = null, string $which = null): bool
{
if (empty($ip))
{
return false;
}
switch (strtolower((string) $which))
{
case 'ipv4':
$which = FILTER_FLAG_IPV4;
break;
case 'ipv6':
$which = FILTER_FLAG_IPV6;
break;
default:
# PROBLEM 2021-03-06 - forced (int)
$which = (int) null;
break;
}
Info
I have been trying for over a week to trace a new site's "Network connection Error" from going down overnight. No errors in logs so added "strict_types=1" to all PHP app and system PHP files, also set .env -> CI_ENVIRONMENT = development and eventually managed to get some errors reported.
Describe the bug
incorrect type being passed.
CodeIgniter 4 version
CI_VERSION 4.1.1
Affected module(s)
File: ./system/Validation/FormatRules.php
[code]
public function valid_ip(string $ip = null, string $which = null): bool
{
if (empty($ip))
{
return false;
}
switch (strtolower((string) $which))
{
case 'ipv4':
$which = FILTER_FLAG_IPV4;
break;
case 'ipv6':
$which = FILTER_FLAG_IPV6;
break;
default:
# PROBLEM 2021-03-06 - forced (int)
$which = (int) null;
break;
}
[/code]
Expected behavior, and steps to reproduce if appropriate
I did not expect the web page to crash :(
Context
OS: [Ubuntu 20.04.1]
Web server [Apache 2]
PHP version [8.0.3]
The text was updated successfully, but these errors were encountered: