diff --git a/src/Constants.ts b/src/Constants.ts index 74668dd4c..4c47e9729 100644 --- a/src/Constants.ts +++ b/src/Constants.ts @@ -118,7 +118,7 @@ export const CONSTANTS: { LatestUpdate: string; } = { VersionString: "1.6.4", - VersionNumber: 15, + VersionNumber: 16, // Speed (in ms) at which the main loop is updated _idleSpeed: 200, diff --git a/src/SaveObject.tsx b/src/SaveObject.tsx index 20f8bb8ec..82fd29ba6 100755 --- a/src/SaveObject.tsx +++ b/src/SaveObject.tsx @@ -398,6 +398,19 @@ function evaluateVersionCompatibility(ver: string | number): void { if (ver < 15) { (Settings as any).EditorTheme = { ...defaultMonacoTheme }; } + //Fix contract names + if (ver < 16) { + //Iterate over all contracts on all servers + for (const server of GetAllServers()) { + for (const contract of server.contracts) { + //Rename old "HammingCodes: Integer to encoded Binary" contracts + //to "HammingCodes: Integer to Encoded Binary" + if (contract.type == "HammingCodes: Integer to encoded Binary") { + contract.type = "HammingCodes: Integer to Encoded Binary"; + } + } + } + } } }