View throws error if event hook name was not declared