mirror of https://github.com/tidwall/tile38.git
fixes #13, invalid object keyword, panic on missing key
This commit is contained in:
parent
b211d9fe15
commit
cd217f05d2
2
build.sh
2
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
|
||||
|
|
|
@ -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" {
|
||||
|
|
Loading…
Reference in New Issue