Skip to content

Commit

Permalink
fix: use correct cache keys
Browse files Browse the repository at this point in the history
  • Loading branch information
lars-reimann committed Oct 6, 2023
1 parent 4bb09a3 commit 64b32f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/language/builtins/safe-ds-module-members.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export abstract class SafeDsModuleMembers<T extends SdsModuleMember> {
const key = `${uri.toString()}#${name}`;

if (this.cache.has(key)) {
return this.cache.get(name);
return this.cache.get(key);
}

if (!this.langiumDocuments.hasDocument(uri)) {
Expand All @@ -37,7 +37,7 @@ export abstract class SafeDsModuleMembers<T extends SdsModuleMember> {
return undefined;
}

this.cache.set(name, firstMatchingModuleMember);
this.cache.set(key, firstMatchingModuleMember);
return firstMatchingModuleMember;
}
}

0 comments on commit 64b32f8

Please sign in to comment.