private void OnDestroy()
        {
            EditorPrefs.SetBool(ignoreUpdatesKey, !checkUpdatesToggle);

            if (windowInstance == this)
            {
                windowInstance = null;
            }
        }
        private static void MaybeOpenWindow()
        {
            //only allow one instance
            if (windowInstance != null)
            {
                return;
            }

            windowInstance = GetWindow <PluginUpdateCheck>(true, pluginName + " Update Check");

            // position/size window
            windowInstance.minSize = new Vector2(335, 360f);
            var rect = windowInstance.position;

            windowInstance.position = new Rect(50f, 50f, rect.width, 360f);

            windowInstance.checkUpdatesToggle = !EditorPrefs.GetBool(ignoreUpdatesKey, false);
        }