checks: fix empty source and target strings causing exceptions.

This should fix nijel/weblate#320
Merge pull request #322 from bertm/patch-2

checks: fix empty source and target strings causing exceptions.