fs.php: add move_or_copy_uploaded

This commit is contained in:
Zankaria 2025-03-18 11:48:53 +01:00
parent 461650a665
commit 3eca4bccc0

View file

@ -8,3 +8,10 @@ function link_or_copy(string $from, string $to) {
}
return true;
}
function move_or_copy_uploaded(string $from, string $to) {
if (!\move_uploaded_file($from, $to)) {
return \copy($from, $to);
}
return true;
}