Improved trigger error message (#930)