void MainWindow_Loaded(object sender, RoutedEventArgs e) { //ServerInfo.Instance.RefreshImportFolders(); if (ServerSettings.MinimizeOnStartup) { MinimizeToTray(); } tabControl1.SelectedIndex = 6; // setup if (ServerSettings.AniDB_Username.Equals("jonbaby", StringComparison.InvariantCultureIgnoreCase) || ServerSettings.AniDB_Username.Equals("jmediamanager", StringComparison.InvariantCultureIgnoreCase)) { btnUploadAzureCache.Visibility = System.Windows.Visibility.Visible; } logger.Info("Clearing Cache..."); Utils.ClearAutoUpdateCache(); ShowDatabaseSetup(); logger.Info("Initializing DB..."); ShokoServer.RunWorkSetupDB(); ShokoServer.Instance.CheckForUpdates(); ShokoServer.Instance.UpdateAvailable += (s, args) => new UpdateForm { Owner = Instance }.ShowDialog(); }