From e8b42cc6c349f18b2c2ab0f0685e8f71aa9688c4 Mon Sep 17 00:00:00 2001 From: arnoudkooi Date: Tue, 5 Nov 2024 20:15:36 +0100 Subject: [PATCH] Minor fixes v8.2.3.4 --- CHANGELOG.md | 9 ++++++--- inject.js | 2 +- js/monaco/settingeditor.js | 2 +- manifest.json | 2 +- 4 files changed, 9 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index bb801a9..fcf45b6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,10 @@ # CHANGELOG.md +## 8.2.3.4 (2024-11-02) +Fixes / changes: + - Fix accidentily renamed file tsWorker.js + - Initialize snusettings object in settingseditor.js, when it is not found in extenson storage (Reddit) + - Fix for link type switches (-t, -erd) to open without a trailing space in the slash command (Slack) + ## 8.2.3.1 (2024-10-29) Fixes / changes: - Bugfix for new setting edittor @@ -11,9 +17,6 @@ Fixes / changes: - Improve handling of "link" type switches autocomplete (Slack) - Changing setting to default on: Prioritize CTRL-/ and CMD-/ above OOB shortcut. - - - ## 8.2.2.1 (2024-10-24) Fixes / changes: - Minor update for Autocomplete for slash command switches (Slack) diff --git a/inject.js b/inject.js index 5d87d99..3fa3d1b 100644 --- a/inject.js +++ b/inject.js @@ -783,7 +783,7 @@ function snuSlashCommandAddListener() { switchValue = snuslashswitchesvalueoverwrites[`${prop}.${tableName}`]; } query = query.replace(val, ""); - if (snuslashswitches[prop].type == "link" && (snufilter + thisKeyWithSpace).includes("-" + prop + " ")) { + if (snuslashswitches[prop].type == "link" && (snufilter + thisKeyWithSpace).includes("-" + prop)) { targeturl = switchValue.replace(/\$0/g, tableName); targeturl = targeturl.replace(/\$sysid/, mySysId); targeturl = snuResolveVariables(targeturl).variableString; diff --git a/js/monaco/settingeditor.js b/js/monaco/settingeditor.js index 970d85e..0f7f6f6 100644 --- a/js/monaco/settingeditor.js +++ b/js/monaco/settingeditor.js @@ -33,7 +33,7 @@ require(['vs/editor/editor.main'], () => { addActions(editor); getFromSyncStorageGlobal("snusettings", function (data) { - let snusettings = data; + let snusettings = data || {}; editor.setValue(snusettings[setting]); setTimeout(() => { editor.getAction('editor.action.formatDocument').run(); diff --git a/manifest.json b/manifest.json index 1548ccf..338bb22 100644 --- a/manifest.json +++ b/manifest.json @@ -3,7 +3,7 @@ "short_name": "SN Utils", "description": "Productivity tools for ServiceNow. (Personal work, not affiliated to ServiceNow)", "author": "Arnoud Kooi / arnoudkooi.com", - "version": "8.2.3.1", + "version": "8.2.3.4", "manifest_version": 3, "permissions": [ "activeTab",