Import: Regex value not correctly set
-
Hello there,
There is a small bug during the importation from a CSV file that set a plain source URL as a regex url.
I found the bug and here is the fix:In file “models/redirect.php” on line 179 change :
$regex = ( isset( $details['regex'] ) && $details['regex'] !== false ) ? 1 : 0;
by
$regex = ( isset( $details['regex'] ) && ((bool)$details['regex']) !== false ) ? 1 : 0;
The type of
$details['regex']
don’t matchfalse
as it is anint
and not a boolean.Hope this will help others and be fixed in next releases.
Thanks
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- The topic ‘Import: Regex value not correctly set’ is closed to new replies.