electron-userland / electron-spellchecker

Implement spellchecking, correctly
MIT License
237 stars 83 forks source link

Fix buildLikelyLocaleTable to not rely on Observable#catch #111

Closed rkistner closed 5 years ago

rkistner commented 6 years ago

If spawn-rx uses a different version/instance of rxjs than electron-spellchecker, there is no #catch() method on the Observable, causing this call to fail.

Additionally, if the spawn did ever fail and the catch block worked, the call would fail in the reduce step with TypeError: Cannot read property 'split' of null.

This fixes these issues.

Fixes #110.

Side note: I don't see any CI system being used, and running the tests don't work out of the box (needs to be passed through babel first), which makes contributing difficult. I'm happy to submit a PR for e.g. testing on Travis if there's interest.

AdrianoFerrari commented 6 years ago

Thanks for the PR @rkistner. I'm facing the same issues, and this does fix them. Could this be merged please, @paulcbetts ?

philfreo commented 6 years ago

@rkistner +1 for setting up a PR for building & testing on Travis. Ideally @paulcbetts would merge that, but if not, at least other forks/contributors could take advantage of it.