   if (registrationKeyQuery) {
            history.replaceState(null, '', '/present');
            document.cookie = `presenter-key=${registrationKeyQuery}; max-age=10800; path=/`;	// 3 hours
        } else {
            // Attempt populating key via cookie
            registrationKeyQuery = getCookieValue('presenter-key');
        }

        var app = Elm.Present.init({
            node: document.getElementById('app'),
            flags: registrationKeyQuery
        });

        var socket = null;
        