Even if you Object.freeze the verified event, nothing in JS will stop you from destructuring it into a new object like that. verify can be a function on the prototype but nothing can guarantee *its* immutability.
It should indeed return false, but what the library does is it stores a thing in the object saying it is verified. You are not supposed to edit it afterwards.
nostr:nprofile1qyt8wumn8ghj7un9d3shjtnddaehgu3wwp6kytcprfmhxue69uhhyetvv9ujuumgd96xvmmjvdjjummwv5hszxthwden5te0dehhxarj9e3k76twve6kuepwv9c8qtcqypuu9jhpzn4z32vpua2eknl8s49ywdfp4rfz5e4m4w06yj8tsg8lvxxqdcn this is your fault! Can we fix it using TypeScript magic or better not even try?
Do you have an actual use case here or were you just playing with the library and saw this craziness nostr:nprofile1qy2hwumn8ghj7un9d3shjtnyv9kh2uewd9hj7qgawaehxw309ahx7um5wghxy6t5vdhkjmn9wgh8xmmrd9skctcpz4mhxue69uhhyetvv9ujumn0wd68ytnzvuhsqgy7r0g9a4q7023dmg0fke9chfytdxasl266yt2y9fy4kxlef2dsxqpm0qt2 ?
Discussion
The implementation must follow the nip46 signer protocol, right? https://nostr-nips.com/nip-46#signer-protocol