cameri / nostream

A Nostr Relay written in TypeScript
MIT License
736 stars 189 forks source link

[BUG] #178

Closed MarkDarwin closed 1 year ago

MarkDarwin commented 1 year ago

Describe the bug Whitelisting pubkeys in .nostr/settings.yml doesn't appear to be working. I get asked for payment again when visiting the relay's site - https://private.red.gb.net

To Reproduce

  1. Visit https://damus.io/key/
  2. Paste my npub key and copy the hex key output
  3. nano .nostr/settings.yml
  4. Replace in two sections, 'info/pubkey' and 'payments/feeSchedules/admission/whiltelists/pubkeys' 'replace-with-your-pubkey-in-hex' with the new hex key
  5. stop and start docker
  6. visit https://private.red.gb.net

Expected behavior I expected to not be presented with another invoice for payment Instead, I was hoping it would show a note saying payment already received

Screenshots image

System (please complete the following information):

Logs Don't have logs but happy to find some if shown which commands to run

Additional context This is a new setup so perhaps I'm not understanding the workflow. If so, apologies

MarkDarwin commented 1 year ago

After more testing, which I should have done before so sorry about that:

If I proceed past the payment request, this is shown in the browser: No admission fee required

I then tested this on another relay which I'd paid for and was shown this in the browser: User is already admitted.

It looks like it is working as designed so feel free to close this as it's not a bug.

It might however be a better end user experience if you could be shown this before committing to potentially paying again.

cameri commented 1 year ago

Glad you were able to figure this one out! We'll definitely look into improving the experience.