Prevent the script from returning 1

This commit is contained in:
Jack L. Frost 2014-09-25 22:16:11 +04:00
parent a4286e8b6c
commit de8733b625

View File

@ -23,8 +23,6 @@ handle_uri() {
handle_fs_target() { handle_fs_target() {
local target="${1##*file://}" local target="${1##*file://}"
[[ -e "$target" ]] || return 1
target_mimetype=$(file -ib "$target") target_mimetype=$(file -ib "$target")
for m in "${!mime_handlers[@]}"; do for m in "${!mime_handlers[@]}"; do
@ -47,9 +45,9 @@ main() {
handle_uri "$target" handle_uri "$target"
fi fi
[[ "$?" -gt 0 ]] && { [[ "$?" -gt 0 ]] && { echo "No handlers found for $target"; }
echo "No handlers found for $target"
} return 0
} }
main "$@" main "$@"