[cmd_import] Removed use of eval; Now redirects argument adequatly for images

This commit is contained in:
ayakael 2018-07-16 05:44:01 -08:00
parent 2f510664c5
commit 77337f5f45
No known key found for this signature in database
GPG key ID: 575626A4AE5F4026

View file

@ -23,7 +23,11 @@
cmd_import() {
local CMD="${1}"
local GIT_DIR="${2}"; shift 2
local dirList=(${@})
local argList=(${@})
[[ "${CMD}" == "cuetools" ]] && cmd_import_images "${GIT_DIR}" CUETOOLS ${argList[@]}
[[ "${CMD}" == "eac" ]] && cmd_import_images "${GIT_DIR}" EAC ${argList[@]}
[[ "${CMD}" == "tracks" ]] && cmd_import_tracks "${GIT_DIR}" ${argList[@]}
eval cmd_import_${CMD} "${GIT_DIR}" ${@}
}