Fixed an issue with "render" method and callbacks

...where class methods could not be used for the callback function
(using the syntax array($this, 'methodName'))