add a conditions to avoid errors
remove the rescue method