Adapted filter for error messages