Fix #2111 IDN not being accepted in queries

This commit is contained in:
Kijin Sung 2023-05-06 22:01:11 +09:00
parent 32ffc94dee
commit 0484d8db27

View file

@ -412,7 +412,7 @@ class VariableBase
break;
case 'homepage':
case 'url':
if (!preg_match('/^(http|https)+(:\/\/)+[0-9a-z_-]+\.[^ ]+$/i', $value))
if (!preg_match('/^https?:\/\//i', $value))
{
throw new \Rhymix\Framework\Exceptions\QueryError('Variable ' . $this->var . ' for column ' . $column . ' must contain a valid URL');
}