Fix the association between measure conditions and certificate

It should use both the certificate type and the code as the key

Fixes: https://www.pivotaltracker.com/story/show/55703024