Skip to content

v0.2.3 — one paste inserts one image

Choose a tag to compare

@pengtang1024 pengtang1024 released this 18 Nov 06:10
· 20 commits to develop since this release

dsh-paste-image 0.2.3

Fixed

  • One paste could insert the same image several times: every copy of the client bundle that had been loaded added another document-level listener, and the old install() returned a no-op disposer so nothing was ever removed. Five loaded copies produced five identical attachments. install() is now idempotent, returns a reference-counted, abort-based disposer that removes both listeners once the last holder releases them, and each source paste/drop event is claimed once, so duplicate listeners can no longer convert and re-route the same event twice.

Tests

  • 21 tests: the new one installs twice, asserts a single paste/drop listener pair, disposes, and installs again.