Fix several places that make use of profiles

because gcr_profiles() returns a list of profiles, not a hash
Merge pull request #2 from rgs/master

Fix several places that make use of profiles