iamraphson / react-paystack

ReactJS library for implementing paystack payment gateway
https://www.npmjs.com/package/react-paystack
MIT License
443 stars 158 forks source link

My Paystack callback event is not firing from today #9

Open wedowebapps opened 6 years ago

wedowebapps commented 6 years ago

Hello I have integrated your package in my react app, and it was working fine till yesterday but from today the callback event is not firing,

Can you please help me with this issue ?

iamraphson commented 6 years ago

Hey @wedowebapps can you share your code?

ahmadmicro commented 6 years ago

I have exactly the same issue. It was working and all of a sudden the callback not firing anymore. I didn't touch the code.

iamraphson commented 6 years ago

@ahmadmicro can you share your code?

iamraphson commented 6 years ago

@ahmadmicro @wedowebapps I can't replicate the issue at the moment. Nevertheless, I have updated the package. Install the latest package and let me know if the issue is still there.

iamraphson commented 6 years ago

@ahmadmicro @wedowebapps can I close this issue, please?

ajanieniolasolomon commented 5 years ago

Paystack callback works only once a day angular4paystack

iamraphson commented 5 years ago

@ajanieniolasolomon react lib or angular4 lib??

ajanieniolasolomon commented 5 years ago

Angular it works just once in a day

On Sun, 2 Dec 2018, 14:39 Ayeni Olusegun, notifications@github.com wrote:

@ajanieniolasolomon https://github.com/ajanieniolasolomon react lib or angular4 lib??

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/iamraphson/react-paystack/issues/9#issuecomment-443508397, or mute the thread https://github.com/notifications/unsubscribe-auth/AVlX-V-jNxr5i4LhWPW2aqpK3JM4E8UMks5u09glgaJpZM4WaTCY .

iamraphson commented 5 years ago

I didn't work on the Angular lib, I worked react and vue lib cc @steveamaza

Larry741 commented 1 year ago

paystack callback event still not firing

Oladapodaniel commented 1 year ago

Im having this issue too, it has been working before, just realised that it has stopped working, and i didnt change the code in anyway

iamraphson commented 1 year ago

Im having this issue too, it has been working before, just realised that it has stopped working, and i didn't change the code in any way

I will be updating the package today. However, Can you share your sample code?

iamraphson commented 1 year ago

Also, @Oladapodaniel when did it stop working?

michaelihuoma01 commented 1 year ago

It suddenly stopped working for me too

osumoclement commented 1 year ago

Same problem here, callbacks were working and all of a sudden doesn't work anymore

jerozeek commented 9 months ago

I also faced the same issue

Solution: Just downgrade to 4.0.3

iamraphson commented 9 months ago

Hi @jerozeek it's callback is working fine for me. Can you share your snippet so i can review?

jerozeek commented 9 months ago

Hi @jerozeek it's callback is working fine for me. Can you share your snippet so i can review?

Here is the code as requested. With version 5.0.4(if am not mistaken) the onSuccess and the onClose were not been called after a successful payment. But when I downgraded it worked 100%

import {usePaystackPayment} from "react-paystack";
import {FC} from "react";
import {IPayments, IPaystackResponse, IPaystackConfig} from "@/utils/interface";
import {CustomButtons} from "@/components/custom/custom.buttons";
import PaymentSummary from "@/components/payment.summary";

type Props = {
    onSuccess: (payload: IPaystackResponse) => void,
    onClose: () => void,
    payload: IPayments,
    config: IPaystackConfig
}

const PayWithPaystack:FC<Props> = ({
   onClose,
   onSuccess,
   payload,
   config,
}) => {

    const PaystackHook = () => {

        const initializePayment = usePaystackPayment(config);

        const _onPay = (event: React.FormEvent<HTMLFormElement>) => {
            event.preventDefault();
            // @ts-ignore
            initializePayment(onSuccess, onClose);
        }

        return (
            <div className={"mt-2 lg:w-[500px] w-full p-2"}>
                <PaymentSummary payment={payload} />
                <form onSubmit={_onPay}>
                    <div className={"w-full mt-2"}>
                        <CustomButtons
                            text={"Confirm Payment"}
                            type={"submit"}
                        />
                    </div>
                </form>
            </div>
        );
    };

    return  <PaystackHook/>

}

export default PayWithPaystack;
Holytech commented 5 months ago

The callback function is not working please

I just used it now, payment was successful but it stays on the page the payment was initiated from (I am using NextJS)

femakin commented 5 months ago

The callback function is not working on v 5.0.0