From e8618820ae32d5b033f278378ac75a5c730de992 Mon Sep 17 00:00:00 2001 From: tituspijean Date: Tue, 3 May 2022 19:01:18 +0200 Subject: [PATCH] Handle already applied patch --- scripts/upgrade | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/upgrade b/scripts/upgrade index 48eed07..450345f 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -116,7 +116,7 @@ then # FIXME because we need to apply the patch manually with --binary flag # while we should be able to simply use the patching feature of ynh_setup_source ynh_add_config --template="../sources/patches/app-CVE-2022-29360.patch.template" --destination="../sources/patches/FIXMEapp-CVE-2022-29360.patch" - patch --silent --binary --forward $final_path/app/rainloop/v/$version/app/libraries/MailSo/Base/HtmlUtils.php <../sources/patches/FIXMEapp-CVE-2022-29360.patch + patched="$(patch --silent --binary --forward $final_path/app/rainloop/v/$version/app/libraries/MailSo/Base/HtmlUtils.php <../sources/patches/FIXMEapp-CVE-2022-29360.patch)" || echo "${patched}" | grep "Reversed (or previously applied) patch detected! Skipping patch." -q || (echo "$patched" && false); fi #=================================================