Fix CRM-12013: Fixed PHP warnings.
Merge pull request #153 from twomice/CRM-12013

Fix CRM-12013: Fixed PHP warnings.