Skip to content

Commit

Permalink
Fixes #300
Browse files Browse the repository at this point in the history
  • Loading branch information
isc-bsaviano committed Jan 17, 2024
1 parent 4bb0fe2 commit 1cc44e0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
- Fix issue [#292](https://github.com/intersystems/language-server/issues/292): Add intellisense for instance variable (i%PropertyName) syntax
- Fix issue [#296](https://github.com/intersystems/language-server/issues/296): Code completion doesn't appear when typing dot in a class name at the class level
- Fix issue [#299](https://github.com/intersystems/language-server/issues/299): Add intellisense for class name parameters
- Fix issue [#300](https://github.com/intersystems/language-server/issues/300): Allow `UnknownUser` to not have a password

## [2.4.0] - 2023-10-17
- Fix issue [#282](https://github.com/intersystems/language-server/issues/282): Syntax error in SQL query using PARTITION or OVER
Expand Down
7 changes: 5 additions & 2 deletions client/src/extension.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,13 +141,16 @@ export async function activate(context: ExtensionContext) {
// Register custom request handlers
client.onRequest("intersystems/server/resolveFromUri", async (uri: string) => {
let serverSpec = objectScriptApi.serverForUri(Uri.parse(uri));
if (serverSpec.username.toLowerCase() == "unknownuser" && typeof serverSpec.password === "undefined") {
// UnknownUser without a password means "unauthenticated"
serverSpec.username = undefined;
}
if (
// Server was resolved
serverSpec.host !== "" &&
// Connection isn't unauthenticated (i.e. UnknownUser)
// Connection isn't unauthenticated
serverSpec.username != undefined &&
serverSpec.username != "" &&
serverSpec.username.toLowerCase() != "unknownuser" &&
// A password is missing
typeof serverSpec.password === "undefined" &&
// A supported version of the Server Manager is installed
Expand Down

0 comments on commit 1cc44e0

Please sign in to comment.