mirror of
https://github.com/unraid/webgui.git
synced 2026-04-28 22:09:24 -05:00
avoid php syntax error if autov() source file does not exist
This commit is contained in:
@@ -231,7 +231,7 @@ function autov($file,$ret=false) {
|
||||
global $docroot;
|
||||
$path = $docroot.$file;
|
||||
clearstatcache(true, $path);
|
||||
$time = strlen(@filemtime($path)) ? @filemtime($path) : 'autov_fileDoesntExist';
|
||||
$time = file_exists($path) ? filemtime($path) : 'autov_fileDoesntExist';
|
||||
$newFile = "$file?v=".$time;
|
||||
if ($ret)
|
||||
return $newFile;
|
||||
|
||||
Reference in New Issue
Block a user