mirror of
https://github.com/PR0M3TH3AN/bitvid.git
synced 2026-10-27 16:02:26 +00:00
Admin list edits worked with a NIP-07 extension but silently failed with nsec and NIP-46 (Amber). persistNostrState signed with window.nostr.signEvent directly (and required requestDefaultExtensionPermissions), so non-extension logins threw "nostr-extension-missing". Fix: sign with the ACTIVE signer (getActiveSigner() from the registry — extension/nsec/ NIP-46 all expose signEvent), and only run the extension-permission prompt when the signer is an extension (type extension/nip07). Regression test in tests/admin-list-store.test.mjs (nsec signer used while window.nostr.signEvent throws). Also (per maintainer request): raise the file-size lint margins to stop churning on an arbitrary cap — THRESHOLD 1000→1200 (new files), GROWTH_MARGIN 50→200 (grandfathered). TODOs added: #42 follow-up audit of every signing path (must use the active signer, not window.nostr); #43 logged-in profile card at the top of the profile modal (half-on/half- off); #44 in-modal storage selector + unlock for the upload modal. Build + lint clean; admin-list suite green. Co-Authored-By: Claude Opus 4.8 <[email protected]>