Fixed NPE at startup.