From 488f563b458dbd6f8bc2af0d51a6131ffdbbffd3 Mon Sep 17 00:00:00 2001 From: OniriCorpe Date: Wed, 28 Aug 2024 23:03:57 +0200 Subject: [PATCH] 2.1 helpers: check if the patches directory exists before trying to get its realpath --- helpers/helpers.v2.1.d/sources | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/helpers/helpers.v2.1.d/sources b/helpers/helpers.v2.1.d/sources index 312014b67..4d7ed1d1e 100644 --- a/helpers/helpers.v2.1.d/sources +++ b/helpers/helpers.v2.1.d/sources @@ -224,8 +224,8 @@ ynh_setup_source() { fi # Apply patches - local patches_folder=$(realpath "$YNH_APP_BASEDIR/patches/$source_id") - if [ -d "$patches_folder" ]; then + if [ -d "$YNH_APP_BASEDIR/patches/" ]; then + local patches_folder=$(realpath "$YNH_APP_BASEDIR/patches/$source_id") pushd "$dest_dir" for patchfile in "$patches_folder/"*.patch; do echo "Applying $patchfile"