fixed bug in error report