added err code