Skip to content

Commit 3bca87c

Browse files
committed
remove Advanced search
1 parent 06f6a2a commit 3bca87c

File tree

3 files changed

+0
-49
lines changed

3 files changed

+0
-49
lines changed

src/kuzzleDataCollection.js

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -73,25 +73,6 @@ function KuzzleDataCollection(kuzzle, collection, index) {
7373
return this;
7474
}
7575

76-
/**
77-
* Executes an advanced search on the data collection.
78-
*
79-
* /!\ There is a small delay between documents creation and their existence in our advanced search layer,
80-
* usually a couple of seconds.
81-
* That means that a document that was just been created won’t be returned by this function.
82-
*
83-
* @deprecated
84-
* @see KuzzleDataCollection.prototype.search
85-
*
86-
* @param {object} filters - Filters in Elasticsearch Query DSL format
87-
* @param {object} [options] - Optional parameters
88-
* @param {responseCallback} cb - Handles the query response
89-
*/
90-
KuzzleDataCollection.prototype.advancedSearch = function (filters, options, cb) {
91-
console.warn('Usage of KuzzleDataCollection.advancedSearch is deprecated. Use KuzzleDataCollection.search instead');
92-
return this.search(filters, options, cb);
93-
};
94-
9576
/**
9677
* Returns the number of documents matching the provided set of filters.
9778
*

test/kuzzleDataCollection/constructor.test.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ describe('KuzzleDataCollection constructor', function () {
4040
kuzzle = new Kuzzle('foo');
4141
dataCollection = new KuzzleDataCollection(kuzzle, 'bar', 'foo');
4242

43-
should.exist(dataCollection.advancedSearchPromise);
4443
should.exist(dataCollection.countPromise);
4544
should.exist(dataCollection.createPromise);
4645
should.exist(dataCollection.createDocumentPromise);

test/kuzzleDataCollection/methods.test.js

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -51,35 +51,6 @@ describe('KuzzleDataCollection methods', function () {
5151
emitted,
5252
kuzzle;
5353

54-
describe('#advancedSearch', function () {
55-
beforeEach(function () {
56-
kuzzle = new Kuzzle('foo', {defaultIndex: 'bar'});
57-
expectedQuery = {
58-
index: 'bar',
59-
collection: 'foo',
60-
action: 'search',
61-
controller: 'read',
62-
body: {}
63-
};
64-
});
65-
66-
it('should call search method', function (done) {
67-
var
68-
searchCalled = false,
69-
collection = kuzzle.dataCollectionFactory(expectedQuery.collection);
70-
71-
collection.search = function(filters, cb) {
72-
searchCalled = true;
73-
cb();
74-
};
75-
76-
collection.advancedSearch({}, function() {
77-
should(searchCalled).be.true();
78-
done();
79-
});
80-
});
81-
});
82-
8354
describe('#search', function () {
8455
beforeEach(function () {
8556
kuzzle = new Kuzzle('foo', {defaultIndex: 'bar'});

0 commit comments

Comments
 (0)