Refactor code to use Zend Coding Style