diff --git a/build.sh b/build.sh index 476b3fba..bffb9ca7 100755 --- a/build.sh +++ b/build.sh @@ -1,7 +1,7 @@ #!/bin/bash set -e -VERSION="1.1.3" +VERSION="1.1.4" PROTECTED_MODE="no" # Hardcode some values to the core package diff --git a/controller/search.go b/controller/search.go index ef6e2a41..9917e21b 100644 --- a/controller/search.go +++ b/controller/search.go @@ -215,7 +215,7 @@ func (c *Controller) cmdSearchArgs(cmd string, vs []resp.Value, types []string) } var nearbyTypes = []string{"point"} -var withinOrIntersectsTypes = []string{"geo", "bounds", "hash", "tile", "quadkey", "get"} +var withinOrIntersectsTypes = []string{"geo", "bounds", "hash", "tile", "quadkey", "get", "object"} func (c *Controller) cmdNearby(msg *server.Message) (res string, err error) { start := time.Now() @@ -274,6 +274,9 @@ func (c *Controller) cmdWithinOrIntersects(cmd string, msg *server.Message) (res if err != nil { return "", err } + if sw.col == nil { + return "", errKeyNotFound + } wr.WriteString(`{"ok":true`) sw.writeHead() if cmd == "within" {