Minor changes I forgot to commit previously

This commit is contained in:
2026-10-20 13:51:10 -04:00
parent 44ee2f1baa
commit 4bf798c5e7
5 changed files with 44 additions and 10 deletions
+5 -1
View File
@@ -61,7 +61,11 @@ namespace NightScout
public virtual void Authorize()
{
JObject authRequest = new JObject {{"client", "web"}};
JObject authRequest;
if (!String.IsNullOrEmpty(NightscoutAlertConfiguration.APISecretKey))
authRequest = new JObject { { "client", "web" }, { "secret", NightscoutAlertConfiguration.APISecretKey } };
else
authRequest = new JObject { { "client", "web" } };
Socket.Emit("authorize", authRequest);
}