File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -207,7 +207,7 @@ CHKSUM="$SUMALGO $(echo -n $KEY | base64 -w 0)"
207
207
# head request
208
208
TUSURL=` tus-config " .[\" $KEY \" ].location?" `
209
209
[[ $LOCATE ]] && info " URL: $TUSURL " && [[ $TUSURL != " null" ]]; [[ $LOCATE ]] && exit $?
210
- [[ " null" != " $TUSURL " ]] && request " --head $TUSURL "
210
+ [[ $TUSURL ]] && [[ " null" != " $TUSURL " ]] && request " --head $TUSURL "
211
211
212
212
if [[ " null" != " $TUSURL " ]] && [[ $ISOK -eq 1 ]]; then
213
213
OFFSET=${HEADERS[Upload-Offset]} LEFTOVER=$(( SIZE - OFFSET))
227
227
-X POST $HOST ${BASEPATH:-/ files/ } "
228
228
229
229
TUSURL=${HEADERS[Location]}
230
+ [[ $TUSURL ]] || error " Tus server replied with empty location. Try changing --base-path param." 1
230
231
231
232
# save location config
232
233
tus-config " .[\" $KEY \" ].location" " $TUSURL "
You can’t perform that action at this time.
0 commit comments