Fixed CRM-14662.

----------------------------------------
* CRM-14662: Fatal error on front-end membership renewal
  https://issues.civicrm.org/jira/browse/CRM-14662
Merge pull request #3204 from GinkgoFJG/CRM-14662

Fixed CRM-14662.