Skip to content

Commit

Permalink
Fixing annotations showing up on incorrect images
Browse files Browse the repository at this point in the history
  • Loading branch information
plt-joey committed Sep 10, 2024
1 parent c1aac28 commit eec641f
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/core/src/RenderingEngine/StackViewport.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2922,7 +2922,13 @@ class StackViewport extends Viewport implements IStackViewport, IImagesLoader {
const colonIndex = imageId.indexOf(':');
imageURI = imageId.substring(colonIndex + 1);
}
return referencedImageId?.endsWith(imageURI);

const referenceColonIndex = referencedImageId.indexOf(':');
const referencedImageURI = referencedImageId.substring(
referenceColonIndex + 1
);

return referencedImageURI === imageURI;
}

/**
Expand Down

0 comments on commit eec641f

Please sign in to comment.