Fixed NPE when rendering Scaffolding