Fix wrong error handling

No match.