style(core): normalize rebase fallout

This commit is contained in:
Peter Steinberger 2026-03-16 00:12:20 -07:00
parent 0ca1b18517
commit e3ab0e174c
No known key found for this signature in database
3 changed files with 9 additions and 4 deletions

View File

@ -1,6 +1,6 @@
import { vi } from "vitest";
import { signalOutbound, telegramOutbound } from "../../test/channel-outbounds.js";
import { parseTelegramTarget } from "../../extensions/telegram/src/targets.js";
import { signalOutbound, telegramOutbound } from "../../test/channel-outbounds.js";
import { loadModelCatalog } from "../agents/model-catalog.js";
import { runEmbeddedPiAgent } from "../agents/pi-embedded.js";
import { runSubagentAnnounceFlow } from "../agents/subagent-announce.js";

View File

@ -1,4 +1,3 @@
import type { CiaoService, Responder } from "@homebridge/ciao";
import { logDebug, logWarn } from "../logger.js";
import { getLogger } from "../logging.js";
import { ignoreCiaoCancellationRejection } from "./bonjour-ciao.js";

View File

@ -194,7 +194,10 @@ export function loadSettings(): UiSettings {
try {
// First check for legacy key (no scope), then check for scoped key
const scopedKey = settingsKeyForGateway(defaults.gatewayUrl);
const raw = storage?.getItem(scopedKey) ?? storage?.getItem(SETTINGS_KEY_PREFIX + "default") ?? storage?.getItem("openclaw.control.settings.v1");
const raw =
storage?.getItem(scopedKey) ??
storage?.getItem(SETTINGS_KEY_PREFIX + "default") ??
storage?.getItem("openclaw.control.settings.v1");
if (!raw) {
return defaults;
}
@ -266,7 +269,10 @@ function persistSettings(next: UiSettings) {
let existingSessionsByGateway: Record<string, ScopedSessionSelection> = {};
try {
// Try to migrate from legacy key or other scopes
const raw = storage?.getItem(scopedKey) ?? storage?.getItem(SETTINGS_KEY_PREFIX + "default") ?? storage?.getItem("openclaw.control.settings.v1");
const raw =
storage?.getItem(scopedKey) ??
storage?.getItem(SETTINGS_KEY_PREFIX + "default") ??
storage?.getItem("openclaw.control.settings.v1");
if (raw) {
const parsed = JSON.parse(raw) as PersistedUiSettings;
if (parsed.sessionsByGateway && typeof parsed.sessionsByGateway === "object") {