validator use static instead of self
Merge branch 'master' of github.com:yiisoft/yii2

* 'master' of github.com:yiisoft/yii2:
  Removed unused namespace.
  Put back Yii::getObjectVars() and fixed infinite loop in Object::toArray().
  Recursively return previous exceptions in toArray().
  Added previous exception in toArray().
  Removed headers in ErrorHandler.