diff --git a/RESOURCES/OPTIONS/bluetooth/bluetooth.sh b/RESOURCES/OPTIONS/bluetooth/bluetooth.sh index 7cfed68..091000a 100755 --- a/RESOURCES/OPTIONS/bluetooth/bluetooth.sh +++ b/RESOURCES/OPTIONS/bluetooth/bluetooth.sh @@ -35,24 +35,10 @@ folders=( "usr/share/alsa/alsa.conf.d/20-bluealsa.conf" ) -# Remove the folders and files -# Check if folder or file and remove it +# Remove everything in the array using -rf for folder in "${folders[@]}"; do - if [ -d "$ROOTFS_DIR/$folder" ]; then - echo "Removing folder: $ROOTFS_DIR/$folder" - rm -rf "$ROOTFS_DIR/$folder" - if [ $? -ne 0 ]; then - echo -e "${RED}ERROR: Failed to remove folder: $ROOTFS_DIR/$folder ${NC}" - exit 3 - fi - elif [ -f "$ROOTFS_DIR/$folder" ]; then - echo "Removing file: $ROOTFS_DIR/$folder" - rm -f "$ROOTFS_DIR/$folder" - if [ $? -ne 0 ]; then - echo -e "${RED}ERROR: Failed to remove file: $ROOTFS_DIR/$folder ${NC}" - exit 3 - fi - fi + echo -e "${YELLOW}INFO: Removing the $ROOTFS_DIR/$folder ...${NC}" + rm -rf $ROOTFS_DIR/$folder done -echo -e "${GREEN}SUCCESS: The 'bluetooth' has been removed ${NC}" +echo -e "${GREEN}INFO: The bluetooth option has been removed${NC}" diff --git a/options.cfg b/options.cfg index bc15ecc..ca2422f 100644 --- a/options.cfg +++ b/options.cfg @@ -76,7 +76,7 @@ kobra_unleashed="localhost.mr-a.de" # Delete the Bluetooth support because it's not used by Kobra Unleashed # and can't be used since we replace mqtt anyways. -# bluetooth="default" +bluetooth="default" # Patch the app to check the captive portal URLs less often (originally every 2s) # It is used to detect if the internet connection is established and alive