forked from leftypol/leftypol
fs.php: add filesystem functions
This commit is contained in:
parent
63ae8f338f
commit
36406a9770
1 changed files with 10 additions and 0 deletions
10
inc/functions/fs.php
Normal file
10
inc/functions/fs.php
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
<?php
|
||||||
|
namespace Vichan\Functions\Fs;
|
||||||
|
|
||||||
|
|
||||||
|
function link_or_copy(string $from, string $to) {
|
||||||
|
if (!\link($from, $to)) {
|
||||||
|
return \copy($from, $to);
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
Loading…
Add table
Add a link
Reference in a new issue