Added handling of not found cases