From f21bf4801e85cd9909e71ea57a57554056e8007d Mon Sep 17 00:00:00 2001 From: Pat Hartl Date: Mon, 20 Nov 2023 18:19:45 -0600 Subject: [PATCH] Fix invalid SQL in migration for scripts --- .../Migrations/20231117064657_DeleteDeprecatedSnippets.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/LANCommander/Migrations/20231117064657_DeleteDeprecatedSnippets.cs b/LANCommander/Migrations/20231117064657_DeleteDeprecatedSnippets.cs index 5ddbac5..5c7ff6e 100644 --- a/LANCommander/Migrations/20231117064657_DeleteDeprecatedSnippets.cs +++ b/LANCommander/Migrations/20231117064657_DeleteDeprecatedSnippets.cs @@ -41,8 +41,8 @@ namespace LANCommander.Migrations migrationBuilder.Sql("UPDATE Scripts SET Contents = REPLACE(Contents, '$NewName', '$NewPlayerAlias')"); migrationBuilder.Sql("UPDATE Scripts SET Contents = REPLACE(Contents, '$OldName', '$OldPlayerAlias')"); migrationBuilder.Sql("UPDATE Scripts SET Contents = REPLACE(Contents, 'function Write-ReplaceContentInFile', 'function Write-ReplaceContentInFile-Old')"); - migrationBuilder.Sql($"UPDATE Scripts SET Contents = REPLACE(Contents, '$args[0]', '$AllocatedKey' WHERE Type = {(int)ScriptType.Install}"); - migrationBuilder.Sql($"UPDATE Scripts SET Contents = REPLACE(Contents, '$args[0]', '$AllocatedKey' WHERE Type = {(int)ScriptType.KeyChange}"); + migrationBuilder.Sql($"UPDATE Scripts SET Contents = REPLACE(Contents, '$args[0]', '$AllocatedKey') WHERE Type = {(int)ScriptType.Install}"); + migrationBuilder.Sql($"UPDATE Scripts SET Contents = REPLACE(Contents, '$args[0]', '$AllocatedKey') WHERE Type = {(int)ScriptType.KeyChange}"); migrationBuilder.Sql("UPDATE Scripts SET Contents = REPLACE(Contents, 'Add-Type -AssemblyName System.Windows.Forms' || char(13) || char(10), '')"); migrationBuilder.Sql("UPDATE Scripts SET Contents = REPLACE(Contents, '$Display = [System.Windows.Forms.Screen]::AllScreens | Where-Object Primary | Select Bounds', '$Display = Get-PrimaryDisplay')"); }