From 0baadf8e02f0c4e84c762e0c5b01a0ffa81a3a89 Mon Sep 17 00:00:00 2001 From: Vincent Vanwaelscappel Date: Mon, 13 Feb 2023 13:16:37 +0100 Subject: [PATCH] wip #5725 @0.25 --- app/src/Tools.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/app/src/Tools.php b/app/src/Tools.php index 4b0a15d..9e76bae 100644 --- a/app/src/Tools.php +++ b/app/src/Tools.php @@ -11,12 +11,18 @@ class Tools { Zip::archive($a['source'], $a['dest'], $a['compression']); } + /** + * @throws \Exception + */ public static function copy($a) { foreach ($a['files'] as $from => $to) { self::_cp($from, $to); } } + /** + * @throws \Exception + */ public static function lazyCopy($a) { foreach ($a['files'] as $from => $to) { if (file_exists($from)) { @@ -25,6 +31,9 @@ class Tools { } } + /** + * @throws \Exception + */ protected static function _cp($from, $to) { Files::mkdir(dirname($to)); Files::copyFile($from, $to); -- 2.39.5