Fix type errors for function validResultProfilesFor. Sorry.