mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-05-31 04:44:05 +02:00
Fix Seafile database selection handling
This commit is contained in:
@@ -119,7 +119,14 @@ bashio::log.info "FILE_SERVER_ROOT set to ${FILE_SERVER_ROOT_VALUE}"
|
||||
|
||||
bashio::log.info "Defining database"
|
||||
|
||||
case $(bashio::config 'database') in
|
||||
# The option is defined as a list, so grab the first entry when an array is
|
||||
# provided (Home Assistant stores multi-select options this way). Fallback to
|
||||
# the raw value to stay compatible with older configurations that used a
|
||||
# string.
|
||||
DATABASE_SELECTION=$(bashio::config 'database[0]' 2>/dev/null || true)
|
||||
DATABASE_SELECTION=${DATABASE_SELECTION:-$(bashio::config 'database')}
|
||||
|
||||
case "${DATABASE_SELECTION}" in
|
||||
|
||||
# Use sqlite
|
||||
sqlite)
|
||||
|
||||
Reference in New Issue
Block a user