fix NPE on the web