Apply suggestions

This commit is contained in:
Cameron 2020-07-31 21:35:01 +01:00
parent df162f3ca3
commit dd0e47a70e
2 changed files with 7 additions and 7 deletions

View File

@ -1,6 +1,8 @@
define(['loading', 'globalize', 'events', 'viewManager', 'skinManager', 'backdrop', 'browser', 'page', 'appSettings', 'apphost', 'connectionManager'], function (loading, globalize, events, viewManager, skinManager, backdrop, browser, page, appSettings, appHost, connectionManager) {
'use strict';
loading = loading.default || loading;
var appRouter = {
showLocalLogin: function (serverId, manualLogin) {
var pageName = manualLogin ? 'manuallogin' : 'login';
@ -22,7 +24,7 @@ define(['loading', 'globalize', 'events', 'viewManager', 'skinManager', 'backdro
function beginConnectionWizard() {
backdrop.clearBackdrop();
loading.default.show();
loading.show();
connectionManager.connect({
enableAutoLogin: appSettings.enableAutoLogin()
}).then(function (result) {
@ -33,7 +35,7 @@ define(['loading', 'globalize', 'events', 'viewManager', 'skinManager', 'backdro
function handleConnectionResult(result) {
switch (result.State) {
case 'SignedIn':
loading.default.hide();
loading.hide();
skinManager.loadUserSkin();
break;
case 'ServerSignIn':
@ -276,7 +278,7 @@ define(['loading', 'globalize', 'events', 'viewManager', 'skinManager', 'backdro
var firstConnectionResult;
function start(options) {
loading.default.show();
loading.show();
initApiClients();
@ -296,7 +298,7 @@ define(['loading', 'globalize', 'events', 'viewManager', 'skinManager', 'backdro
hashbang: options.hashbang !== false
});
}).catch().then(function() {
loading.default.hide();
loading.hide();
});
}
@ -511,7 +513,7 @@ define(['loading', 'globalize', 'events', 'viewManager', 'skinManager', 'backdro
if (currentRouteInfo && currentRouteInfo.path === path) {
// can't use this with home right now due to the back menu
if (currentRouteInfo.route.type !== 'home') {
loading.default.hide();
loading.hide();
return Promise.resolve();
}
}

View File

@ -17,8 +17,6 @@ import 'flexStyles';
/* eslint-disable indent */
loading = loading.default || loading;
function itemsPerRow() {
const screenWidth = dom.getWindowSize().innerWidth;