Proper way to check intent