only return flags if they exist