fix 500 when Product or Feature rate is assigned without assigning a Role

Fixes http://manage.dimagi.com/default.asp?97059#551992 and http://manage.dimagi.com/default.asp?97063.