Fixing few bugs with error message collection