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

After successful payment redirects to /undefined #3

Closed
reathh opened this issue Apr 24, 2018 · 4 comments
Closed

After successful payment redirects to /undefined #3

reathh opened this issue Apr 24, 2018 · 4 comments

Comments

@reathh
Copy link

reathh commented Apr 24, 2018

I setup a page (and a publication if that matters, I tried both) and added the [ifpaid 0.05 USD] attribute. The "Pay" button shows and after clicking it an invoice is created which I am able to successfully pay.

The problem occurs after I pay, the page refreshes but no token is appended to the url, rather the url changes from sondaji.com/test-publication/ to sondaji.com/test-publication/undefined which in result gives me the Wordpress 404 page

I can create a video demonstrating the process, but it's pretty straightforward. In my c-lightning log I see that the payment is successful:
lightningd(15538): Resolving invoice 'iVvfFzu~OmsWELQSUYq0z' with HTLC 5

lightning-charge also indicates success:
GET /checkout/iVvfFzu~OmsWELQSUYq0z/wait 204 8915.376 ms - -
GET /invoice/iVvfFzu%7EOmsWELQSUYq0z 200 2.333 ms - 816

Picture 1: Qr Code
2018-04-24_13-56-46

Picture 2: Redirected page after successful payment:
2018-04-24_13-58-50

@shesek
Copy link
Collaborator

shesek commented Apr 25, 2018

Once the payment is made, there's a POST request sent to /wp-admin/admin-ajax.php with action=ln_publisher_token in its request body. Can you look for this using the browser's web developer tools and copy the response you're getting from the server? This should be a JSON object with the post_id, token and url fields.

Also, might be easier if we diagnose this over IM. Twitter DMs or IRC (Freenode) perhaps?

@reathh
Copy link
Author

reathh commented Apr 25, 2018 via email

@reathh
Copy link
Author

reathh commented May 16, 2018

Nothing?

@shesek
Copy link
Collaborator

shesek commented Jul 14, 2018

Hi, sorry for the long delay! This was caused due to a change in Lightning Charge that caused incompatibility, and was fixed in Lightning Publisher v0.1.8.

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

No branches or pull requests

2 participants