Fix to JS-236 NPE