Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix hardcoded domains #48

Merged
merged 2 commits into from
Aug 30, 2024
Merged

Fix hardcoded domains #48

merged 2 commits into from
Aug 30, 2024

Conversation

sbddesign
Copy link
Contributor

@sbddesign sbddesign commented Aug 30, 2024

This is a fix for #33 and issues with latest staging to master PR. Basically, 12cash.dev was hardcoded in some places. To fix this, I had to move the new paycode form into a client component, determine the appropriate domain to use from within the erver page /new, and then pass the domain into the client component.

This expects to find either 12cash.dev or twelve.cash in the env, meaning on staging or dev you want:

DOMAINS={"12cash.dev": "def456"} #staging

and on prod you want:

DOMAINS={"twelve.cash": "abc123"} #production

In future, we can add support for pulling other fun domains from the DOMAINS object and have a way to specify which is the default in the list.

  • pull domains from env
  • added new form to client component

Copy link

netlify bot commented Aug 30, 2024

Deploy Preview for twelvecash ready!

Name Link
🔨 Latest commit a0a3250
🔍 Latest deploy log https://app.netlify.com/sites/twelvecash/deploys/66d1fdd1ce05c1000841e626
😎 Deploy Preview https://deploy-preview-48--twelvecash.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@sbddesign sbddesign changed the base branch from main to staging August 30, 2024 17:14
@sbddesign sbddesign requested a review from chdwlch August 30, 2024 17:14
Copy link
Collaborator

@chdwlch chdwlch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Totally forgot about the hardcoded 12cash.dev there. Thanks for fixing.

@sbddesign
Copy link
Contributor Author

I did find a bug where it did not go to confetti after paying, so I'll fix that in another PR

@sbddesign sbddesign merged commit 5561698 into staging Aug 30, 2024
4 checks passed
@sbddesign sbddesign deleted the fix-hardcode-domains branch August 30, 2024 21:02
sbddesign added a commit that referenced this pull request Oct 4, 2024
* User Accounts and Paid User Names (#35)

* add initial prisma schema

* intial prisma, nostr auth, mess

* store jwt in httponly cookie, user hook, user ctx in trpc

* add logout button and route to expire/delete cookie

* add getUserServer from token, fix window bug, setUser on log in

* add random paycode trpc endpoint

* remove v2 record route

* get user paycodes endpoint

* display paycodes on account page

* add paid paycode flow, need to hook up ln node rest

* add qr code

* add lnd rest create invoice lookup invoice

* limit userName input characters to a-z, 0-9, ., -, _

* move to .env for prisma

* add db steps to readme

* User Accounts UI (#37)

* tidy up login page

* nostr login cleanup

* account page cleanup

* added toggle ui for paid and free

* spruced up invoice screen

* swapped paid page into new page

* simplified command in readme

* add the ability to use both paid and free endpoints in the new ui (#38)

* add the ability to use both paid and free endpoints in the new ui

* centered footer

---------

Co-authored-by: Stephen DeLorme <[email protected]>

---------

Co-authored-by: Chad Welch <[email protected]>

* Mobile Fixes (#42)

* mobile hamburger menu

* improved home page on mobile

* mobile fixes for check page

* mobile fixes to account page

* mobile fixes to username creation

* Fix and test createBip21FromParams function (#43)

* fix createBip21 tests to use new parameters

* fix and test createBip21FromParams

* update pricing (#46)

* Fix hardcoded domains (#48)

* pull domains from env

* added new form to client component

* Social metadata (#52)

* add metadata for #39 and #40

Co-authored-by: Paulo Sacramento <[email protected]>

* overwrite facicon file

Co-authored-by: Paulo Sacramento <[email protected]>

---------

Co-authored-by: Paulo Sacramento <[email protected]>

* temp remove reference to ln addr until conversion is added

---------

Co-authored-by: Chad Welch <[email protected]>
Co-authored-by: Paulo Sacramento <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants