Fix CRM-12013.
Merge pull request #122 from twomice/CRM-12013

Fix CRM-12013.