mirror of
https://github.com/openclaw/openclaw.git
synced 2026-02-19 18:39:20 -05:00
fix: remove unused imports and simplify boolean comparison
This commit is contained in:
committed by
Peter Steinberger
parent
fe613297a7
commit
1bb2d65ff3
@@ -50,7 +50,7 @@ class I18nManager {
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
this.translations[locale] = module[locale.replace("-", "_")] as TranslationMap;
|
||||
this.translations[locale] = module[locale.replace("-", "_")];
|
||||
} catch (e) {
|
||||
console.error(`Failed to load locale: ${locale}`, e);
|
||||
return;
|
||||
|
||||
@@ -51,17 +51,13 @@ import {
|
||||
saveSkillApiKey,
|
||||
updateSkillEdit,
|
||||
updateSkillEnabled,
|
||||
type SkillMessage,
|
||||
} from "./controllers/skills.ts";
|
||||
import { icons } from "./icons.ts";
|
||||
import {
|
||||
normalizeBasePath,
|
||||
TAB_GROUPS,
|
||||
iconForTab,
|
||||
pathForTab,
|
||||
subtitleForTab,
|
||||
titleForTab,
|
||||
type Tab,
|
||||
} from "./navigation.ts";
|
||||
import { renderAgents } from "./views/agents.ts";
|
||||
import { renderChannels } from "./views/channels.ts";
|
||||
|
||||
@@ -86,7 +86,7 @@ export function renderOverview(props: OverviewProps) {
|
||||
return null;
|
||||
}
|
||||
const isSecureContext = typeof window !== "undefined" ? window.isSecureContext : true;
|
||||
if (isSecureContext !== false) {
|
||||
if (isSecureContext) {
|
||||
return null;
|
||||
}
|
||||
const lower = props.lastError.toLowerCase();
|
||||
|
||||
Reference in New Issue
Block a user