magento/magento2 — pull request #268 by mrploddy (2013-03-22 17:20:11+00:00)
Title: Update Zend.php

I came across a bug with Payment methods and I'm guessing it might also come up elsewhere.

I'm writing a test payment gateway for Sagepay form and in the declaration in the config.xml there was a spelling mistake in the payment code so that it didn't match up with the payment code declared in the Model eg

Config.xml

sagepayform
0
JuicyMedia_Sagepayform_Model_Sagepayform

Sagepayform

0

And in the Model -
class JuicyMedia_Sagepayform_Model_Sagepayform extends Mage_Payment_Model_Method_Abstract
{
protected $_code = 'sagepayform';

Because there was this spelling mistake it was creating an exception in /lib/Magento/Di/Zend.php

This pull request therefore is a way of making sure that Magento error's out properly with an exception instead of a PHP fatal error message.

This is only one specific use case but Im guessing there are other examples where this might occur.