From cfb805b2988d1f2f746a64f995522807468a05d8 Mon Sep 17 00:00:00 2001 From: guyincognito24601 <32616257+guyincognito24601@users.noreply.github.com> Date: Mon, 9 Oct 2017 21:46:38 -0400 Subject: [PATCH] Split local variable declaration from assignment (#205) This allows the return code to be correctly set. Previously, RET was always being set to 0... the result of assigning the local variable. --- plexupdate-core | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/plexupdate-core b/plexupdate-core index f7bbcce..efd40e7 100755 --- a/plexupdate-core +++ b/plexupdate-core @@ -179,7 +179,8 @@ getLocalSHA() { # RNNG running() { # If a server is unclaimed, it probably doesn't have TLS enabled either - local DATA="$(wget -q -O - http://$1:$2/status/sessions)" + local DATA + DATA="$(wget -q -O - http://$1:$2/status/sessions)" local RET=$? if [ ${RET} -eq 6 ]; then