EventIndex: Hide the feature behind a labs flag.
This commit is contained in:
parent
979803797f
commit
f776bdcc8b
3 changed files with 13 additions and 1 deletions
|
@ -21,6 +21,7 @@ limitations under the License.
|
|||
|
||||
import PlatformPeg from "./PlatformPeg";
|
||||
import EventIndex from "./EventIndex";
|
||||
import SettingsStore from './settings/SettingsStore';
|
||||
|
||||
class EventIndexPeg {
|
||||
constructor() {
|
||||
|
@ -34,6 +35,10 @@ class EventIndexPeg {
|
|||
* EventIndex was successfully initialized, false otherwise.
|
||||
*/
|
||||
async init() {
|
||||
if (!SettingsStore.isFeatureEnabled("feature_event_indexing")) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const indexManager = PlatformPeg.get().getEventIndexingManager();
|
||||
if (!indexManager || await indexManager.supportsEventIndexing() !== true) {
|
||||
console.log("EventIndex: Platform doesn't support event indexing,",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue