mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-28 14:15:24 +00:00
fix: finish 2.9.0 plugin moves and get every check green
This commit is contained in:
1 parent
8c1e02af89
commit
6489b62ece
335 files changed
+29878
-17749
No files matched your search
@@ -28,6 +28,19 @@ export async function activate(ctx: PluginContext) {
|
||||
order: 20,
|
||||
});
|
||||
|
||||
// A host's profileId is a local row id; remote sync carries the profile's
|
||||
// syncId instead, which is the same on both sides.
|
||||
ctx.registry.provide("vault.hostSettingsSync", {
|
||||
exportValue: async (key: string, value: unknown) =>
|
||||
key === "profileId" && typeof value === "number"
|
||||
? ((await profiles.findById(value))?.syncId ?? null)
|
||||
: value,
|
||||
importValue: async (key: string, value: unknown) =>
|
||||
key === "profileId" && typeof value === "string"
|
||||
? ((await profiles.findBySyncId(value))?.id ?? null)
|
||||
: value,
|
||||
});
|
||||
|
||||
registerRoutes(
|
||||
ctx,
|
||||
ctx.http.router<Router>({ public: PUBLIC_PATHS }),
|
||||
|
||||
@@ -84,6 +84,7 @@ export function createProfileStore(
|
||||
|
||||
return {
|
||||
findById,
|
||||
findBySyncId,
|
||||
|
||||
/** The user's own profiles plus every shared one. */
|
||||
async listVisible(userId: string): Promise<ProfileRow[]> {
|
||||
|
||||
Reference in new issue
Block a user