LPS-36331 we don't support folders search when using database (and fix problem when using lucene)