Fixed the error handling that use a "Try".