#ismailelric

1 messages · Page 1 of 1 (latest)

next nicheBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

old onyx
#

Once you call connectXXXX function, I believe the discovery stops. If the connection process is interrupted and doesn't complete then you'd need to call discoverReaders again

#

as far as I remember

analog rivet
#

Okay. The issue is that if a reader is connected, other readers are no longer displayed as well. any idea how I can store discovered readers?

old onyx
#

You could always store it in local storage, what's the usecase?

analog rivet
#

I intend on storing them in a state hook. however, the discoverReader only returns an error object

const discoverReaders: (params: DiscoverReadersParams) => Promise<{
    error?: StripeError<CommonError>;
}>
#

I can use useMemo, but that is likely to cause unnecessary renders

old onyx
analog rivet
#

Yes, which happens to get cleared up when using connectXXX

#

didUpdateDiscoveredReaders is no longer available

old onyx
#

how exactly are you attempting to store them before calling connectXXXX ?

#

I intend on storing them in a state hook. however, the discoverReader only returns an error object
do you mean discoveredReaders instead? Is there a typo in your code?

analog rivet
#

You are right. I want to store discoveredCardReaders.

#

The information you provided on this will do. Thank you.

old onyx
#

Perfect