fixed error handling
updated readme