Open rickwh77 opened 3 years ago
Looks like the interval isn't cleaned up from useEffect and so capture
gets called after teardown... and when it's called, the ref.current is null.
The current master uses optional chaining and so you shouldn't get the error but it still needs cleanup.
Here is a commit where I do it on my fork:
I am having an issue with getting this error when using a ternary operator to hide the barcode scanner.![image](https://user-images.githubusercontent.com/75914867/118564463-e9e23d80-b735-11eb-9a8f-c45d4ae3818b.png)