I have been using your library for a few months now and it has been awesome! 🎉Has allowed me to build an app that would've been unthinkable otherwise.
Unfortunately, I have noticed that there are some app crashes that appear to stem from the library. I'm not an expert on this source code nor an iOS developer, but after some debugging it appears that there were issues with multiple functions manipulating the links and nearbyUsers arrays simultaneously.
The errors were as below:
These crashes occurred when I had multiple devices connected, and started toggling some of them in and out of airplane mode to simulate disconnection and reconnection.
I fixed the issue used a synchronous dispatch queue and looping backwards instead of forwards to protect the links and nearbyUsers array indices.
I went ahead and forked the repo to make changes and everything looks good on my end now. I just wanted to propose this code to you in case you feel it is an improvement to the codebase.
Also, if you see anything that I've done that doesn't seem right feel free to let me know. Thanks!
Hello @alexkendall !
I have been using your library for a few months now and it has been awesome! 🎉Has allowed me to build an app that would've been unthinkable otherwise.
Unfortunately, I have noticed that there are some app crashes that appear to stem from the library. I'm not an expert on this source code nor an iOS developer, but after some debugging it appears that there were issues with multiple functions manipulating the
links
andnearbyUsers
arrays simultaneously.The errors were as below:
These crashes occurred when I had multiple devices connected, and started toggling some of them in and out of airplane mode to simulate disconnection and reconnection.
I fixed the issue used a synchronous dispatch queue and looping backwards instead of forwards to protect the
links
andnearbyUsers
array indices.I went ahead and forked the repo to make changes and everything looks good on my end now. I just wanted to propose this code to you in case you feel it is an improvement to the codebase.
Also, if you see anything that I've done that doesn't seem right feel free to let me know. Thanks!