Fixes Bug 176537. Sonnet fails to autodetect a language if there are no trigrams available for the language. In some cases, the script of the language is detected exactly but only because no trigrams were found for the language in question, autodetection fails.
Additionally, I have tested and patched it in QOwnNotes and it is working pretty well there.