FIREBASE WARNING: Using an unspecified index

1

I'm getting the following error:

  

FIREBASE WARNING: Using an unspecified index. Consider adding   ".indexOn": "route" at / drivers to your security rules for better   performance

Firebase rules:

{
    "rules": {
        ".read": "true",
        ".write": "true",
        ".indexOn": "gameSearching"
    }
}

My .ts file

initItems(serchQuery="gameSearching") {
return this.afDatabase.list('/motoristas', {
  query: {
    orderByChild: 'rota',
    equalTo: serchQuery
   }
 });
}
    
asked by anonymous 28.08.2017 / 14:23

1 answer

0

As we talked about the comments, add something like:

{
  "rules": {
    "motoristas": {
      ".indexOn": ["nombre"]
    }
  }
}

In your rules you must solve.

Source: link

    
28.08.2017 / 15:04