realpath returns the canonicalized absolute pathname
This commit is contained in:
parent
15c4da62d9
commit
9f3a31aeab
@ -30,7 +30,7 @@ class DauxHelper
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (is_dir($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])) {
|
if (is_dir(realpath(($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])))) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -43,7 +43,7 @@ class DauxHelper
|
|||||||
$params['html']['theme'] = array_pop($theme);
|
$params['html']['theme'] = array_pop($theme);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!is_dir($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])) {
|
if (!is_dir(realpath(($params['themes_path'] . DIRECTORY_SEPARATOR . $params['html']['theme'])))) {
|
||||||
throw new \RuntimeException("Theme '{$params['html']['theme']}' not found");
|
throw new \RuntimeException("Theme '{$params['html']['theme']}' not found");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user