Commit ebc7b859 authored by Davide Aprea's avatar Davide Aprea

modified regex for url validation

parent 42f1c343
......@@ -290,8 +290,8 @@ class SettingsController extends Controller
$blacklist = substr($blacklist, 0, stripos($blacklist, '/'));
}
$regexUrl = '#^(\*\.)?[a-z0-9.]*$#';
if(preg_match($regexUrl, $blacklist) == 1){
$regexUrl = '#^[a-z0-9]+(\.[a-z0-9]{2,})+$#';
if(preg_match($regexUrl, $blacklist) === 1){
$path = \Request::path();
$cookiePath = "/" . substr($path, 0, strpos($path, "meta/") + 5);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment