Skip to content

Commit

Permalink
add migration
Browse files Browse the repository at this point in the history
  • Loading branch information
Dominion5254 committed Jun 6, 2024
1 parent b85f90b commit 22bc02a
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions scripts/services/migrations.ts
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,33 @@ export const migration: T.ExpectedExports.migration = compat.migrations
throw new Error("Cannot downgrade");
},
},
"0.18.0": {
up: compat.migrations.updateConfig(
(config: any) => {
config.advanced["protocol-zero-conf"] = false;
config.advanced["protocol-option-scid-alias"] = false;
return config;
},
false,
{ version: "0.18.0", type: "up" }
),
down: compat.migrations.updateConfig(
(config) => {
if (matches.shape({
advanced: matches.shape({
"protocol-zero-conf": matches.any,
"protocol-option-scid-alias": matches.any,
})
}).test(config)) {
delete config.advanced["protocol-zero-conf"];
delete config.advanced["protocol-option-scid-alias"];
}
return config;
},
true,
{ version: "0.18.0", type: "down" }
)
}
},
"0.18.0",
);

0 comments on commit 22bc02a

Please sign in to comment.