Truncate error messages for storing