Subject: | AnyEvent::CouchDB::Database->view should special case group => 1|0 |
When passing the 'group' option to the
AnyEvent::CouchDB::Database->view, I encountered the following error:
[
{
HTTPVersion => "1.0",
Reason => "Internal Server Error",
Status => 500,
URL => "http://localhost:5984/jot/_view/tasks/total?group=1",
"content-length" => 64,
"content-type" => "text/plain;charset=utf-8",
date => "Wed, 10 Dec 2008 17:02:39 GMT",
server => "MochiWeb/1.0 (Any of you quaids got a smint?)",
},
{ error => "query_parse_error", reason => "Bad URL query key:group" },
] at tt.pl line 12
This can be fixed by passing group => 'true', but it is probably best to
special case this parameter.
Something like this, in the 'our $query' function ref:
if ($name eq 'group') {
$value = $value ? 'true' : 'false';
}
A copy of Database.pm with a change like this is attached.
It seems a bit silly to generate a patch for this.
Subject: | Database.pm |
Message body is not shown because it is too large.