setup wizard: parse shareHandler and memIndex fields as booleans

http://camlistore.org/issue/128

Change-Id: Iee55f4e758a0429d6490efe745f5256580efee6e
This commit is contained in:
mpl 2013-04-01 17:04:09 +02:00
parent b410b1df6e
commit 17119dade8
1 changed files with 2 additions and 2 deletions

View File

@ -186,10 +186,10 @@ func handleSetupChange(rw http.ResponseWriter, req *http.Request) {
}
switch k {
case "https":
case "https", "shareHandler", "memIndex":
b, err := strconv.ParseBool(v[0])
if err != nil {
httputil.ServeError(rw, req, fmt.Errorf("https field expects a boolean value"))
httputil.ServeError(rw, req, fmt.Errorf("%v field expects a boolean value", k))
}
el = b
case "replicateTo":