Fixed for ES search engine after major changes of the code