moved handling of error messages to single service