Fix issue js function duplication issue.