Fixed compatibility issues with Nette 2.1