浏览代码

Change command check to fully pass shellcheck

aattww 5 年之前
父节点
当前提交
c064b3896a
共有 1 个文件被更改,包括 1 次插入3 次删除
  1. 1 3
      dnsapi/dns_joker.sh

+ 1 - 3
dnsapi/dns_joker.sh

@@ -120,9 +120,7 @@ _joker_rest() {
   data="$1"
   data="$1"
   _debug data "$data"
   _debug data "$data"
 
 
-  response="$(_post "$data" "$JOKER_API" "" "POST")"
-
-  if [ "$?" != "0" ]; then
+  if ! response="$(_post "$data" "$JOKER_API" "" "POST")"; then
     _err "Error POSTing"
     _err "Error POSTing"
     return 1
     return 1
   fi
   fi