From e1c5036fb4b1fafb3f54549d5c6881b027d42745 Mon Sep 17 00:00:00 2001 From: Tsu-ba-me Date: Fri, 28 May 2021 16:47:40 -0400 Subject: [PATCH] fix(cgi-bin): add switch support to get_networks --- cgi-bin/get_networks | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cgi-bin/get_networks b/cgi-bin/get_networks index 56916d74..ac99f348 100755 --- a/cgi-bin/get_networks +++ b/cgi-bin/get_networks @@ -213,7 +213,7 @@ $anvil->Database->get_anvils(); print $anvil->Template->get({file => "shared.html", name => "json_headers", show_name => 0})."\n"; -my $anvil_uuid = $anvil->data->{cgi}{anvil_uuid}{value}; +my $anvil_uuid = exists $anvil->data->{cgi}{anvil_uuid}{value} ? $anvil->data->{cgi}{anvil_uuid}{value} : $anvil->data->{switches}{'anvil-uuid'}; my $anvil_uuid_variable_name = "anvil UUID"; my $response_body = {};