TrueCar / react-launch-darkly

Simple component helpers to support LaunchDarkly in your React app.
MIT License
76 stars 20 forks source link

Empty out onReady queue with execution (fix safari stack size exceeded bug with identify use) #83

Closed msied closed 6 years ago

msied commented 6 years ago

Resolves https://github.com/TrueCar/react-launch-darkly/issues/82 .

On Safari, the ldClient's ready event is fired multiple times, resulting in the queue being executed successively each time. To resolve, we empty out the queue after each callback is executed.

truecar-cla-bot commented 6 years ago

Hey @msied, it looks like you haven\'t signed our Contributor License Agreement, yet.

The purpose of a CLA is to ensure that the guardian of a project\'s outputs has the necessary ownership or grants of rights over all contributions to allow them to distribute under the chosen license. Wikipedia

You can read and sign our full Contributor License Agreement here.

Once you\'ve signed reply with [clabot:check] to prove it.

Appreciation of efforts,

clabot

msied commented 6 years ago

[clabot:check]

truecar-cla-bot commented 6 years ago

@TrueCar It looks like @msied just signed our Contributor License Agreement. :+1:

Always at your service,

clabot

jacobmoretti commented 6 years ago

@msied Nice catch! Thanks for opening an issue and submitting the PR. LGTM 💯 The only curious thing is that we haven't seen this bug in any of our error reporting. In either case, this change is a good one. Probably good to empty out the queue in any regard.