Fix NPE in Tomcat without CDI