Remove reference to deprecated makepathsafe() function

This commit is contained in:
Junior 2023-08-18 13:29:26 -04:00
parent 25bac47c3e
commit 1998cfb68b

View File

@ -13,12 +13,9 @@ if ( isset($_REQUEST['sortorder']) ) {
$validext = array('cbr', 'cbz'); $validext = array('cbr', 'cbz');
if ( isset($_REQUEST['newpath']) ) { if ( isset($_REQUEST['newpath']) ) {
$newpath = makepathsafe($_REQUEST['newpath']); $comicfull = realpath(COMICSDIR . base64_decode(urldecode($_REQUEST['newpath'])));
if ( is_dir(COMICSDIR . $newpath) ) { if ( ($comicfull === false) || (substr($comicfull, 0, strlen(COMICSDIR)) != COMICSDIR) ) $_SESSION['compath'] = "/";
$_SESSION['compath'] = $newpath; $_SESSION['compath'] = substr($comicfull, strlen(COMICSDIR));
} else {
$_SESSION['compath'] = "/";
}
} }
$compath = $_SESSION['compath']; $compath = $_SESSION['compath'];