This code works:

```
firebase.database().ref($scope.language).orderByChild('word').equalTo($scope.word).once('value')
  .then(function(snapshot) {
    console.log(snapshot.val());
  })

```

It logs the object and its key.

This code doesn't work:

```
firebase.database().ref($scope.language).orderByChild('word').equalTo($scope.word).remove()
  .then(function(snapshot) {
    console.log("Removed!");
  })

```

The error message is:

```
TypeError: firebase.database(...).ref(...).orderByChild(...).equalTo(...).remove is not a function

```

The [documentation](https://firebase.google.com/docs/reference/js/firebase.database.Reference#remove) makes `remove()` look simple. What am I missing?