Fixed where system won't register if no uuid in config (from manual config)

This commit is contained in:
Heath Volmer
2018-08-01 15:30:10 -06:00
parent 1371c728c5
commit 7e8cdd738f
3 changed files with 15 additions and 3 deletions

View File

@@ -188,6 +188,12 @@ namespace PepperDash.Essentials
/// <param name="command"></param>
void AuthorizeSystem(string code)
{
if (string.IsNullOrEmpty(SystemUuid))
{
CrestronConsole.ConsoleCommandResponse("System does not have a UUID. Please ensure proper portal-format configuration is loaded and restart.");
return;
}
if (string.IsNullOrEmpty(code))
{
CrestronConsole.ConsoleCommandResponse("Please enter a user code to authorize a system");
@@ -274,6 +280,8 @@ namespace PepperDash.Essentials
/// <param name="url">URL of the server, including the port number, if not 80. Format: "serverUrlOrIp:port"</param>
void RegisterSystemToServer()
{
var ready = RegisterLockEvent.Wait(20000);
if (!ready)
{