Added begin..rescue block