database: fix term count error better

This commit is contained in:
Cadey Ratio 2017-03-26 13:27:25 -07:00
parent 676c373356
commit 73c2e41af7
1 changed files with 1 additions and 1 deletions

View File

@ -67,7 +67,7 @@ func (db *DB) SaveRoute(resp *routerpc.AddHostResponse) error {
} }
func (db *DB) GetRouteForHost(name string) (*Route, error) { func (db *DB) GetRouteForHost(name string) (*Route, error) {
rows, err := r.Table("routes").Filter(r.Row.Field("hostname", name)).Run(db.s) rows, err := r.Table("routes").Filter(map[string]interface{}{"hostname": name}).Run(db.s)
if err != nil { if err != nil {
return nil, err return nil, err
} }