mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 09:48:58 -04:00
allow expernal code to get a list of sources that the are courier considers open, without having to access internal properties
This commit is contained in:
parent
f5ba7bcdda
commit
cb9c9a4d81
1 changed files with 12 additions and 0 deletions
|
@ -286,5 +286,17 @@ define(function (require) {
|
|||
this.fetch('doc');
|
||||
};
|
||||
|
||||
// get the list of open data source objects
|
||||
// primarily for testing purposes
|
||||
Courier.prototype._openSources = function (type) {
|
||||
if (!type) {
|
||||
return _.transform(this._refs, function (open, refs) {
|
||||
[].push.apply(open, refs);
|
||||
}, []);
|
||||
}
|
||||
|
||||
return this._refs[type] || [];
|
||||
};
|
||||
|
||||
return Courier;
|
||||
});
|
Loading…
Add table
Add a link
Reference in a new issue