mirror of
https://github.com/YunoHost-Apps/nextcloud_ynh.git
synced 2024-09-03 19:55:57 +02:00
Merge pull request #282 from YunoHost-Apps/fix-backward-nc-14-or-older
[fix] Backward compatibility for NC 14 or older
This commit is contained in:
commit
1597abe3d6
1 changed files with 8 additions and 1 deletions
|
@ -199,8 +199,15 @@ fi
|
||||||
|
|
||||||
# Define a function to execute commands with `occ`
|
# Define a function to execute commands with `occ`
|
||||||
exec_occ() {
|
exec_occ() {
|
||||||
|
# Backward compatibility to upgrade from NC14 or older version
|
||||||
|
if [ $current_major_version -lt 15 ]
|
||||||
|
then
|
||||||
|
NEXTCLOUD_PHP_VERSION="7.0"
|
||||||
|
else
|
||||||
|
NEXTCLOUD_PHP_VERSION=$YNH_PHP_VERSION
|
||||||
|
fi
|
||||||
(cd "$final_path" && exec_as "$app" \
|
(cd "$final_path" && exec_as "$app" \
|
||||||
php$YNH_PHP_VERSION occ --no-interaction --no-ansi "$@")
|
php$NEXTCLOUD_PHP_VERSION occ --no-interaction --no-ansi "$@")
|
||||||
}
|
}
|
||||||
|
|
||||||
# Define a function to add an external storage
|
# Define a function to add an external storage
|
||||||
|
|
Loading…
Add table
Reference in a new issue