Returned broken resources
Added catch block that returns broken resource in case of Exception.
Fixed exception handling.