code: public static final <T extends JavaScriptObject> T checkNull(T js) {
      if (!GWT.isProdMode() && js == null) {
        throw new NullPointerException();
      }
      return js;
    }
docs: Throw a NPE when a js is null.