--- trunk/lib/Frey/CouchAPI.pm 2009/04/23 20:12:45 1052 +++ trunk/lib/Frey/CouchAPI.pm 2009/04/23 20:24:48 1053 @@ -23,8 +23,8 @@ use File::Path qw(make_path remove_tree); use Storable; -our $VERSION = '0.1'; -$VERSION .= ' on Frey ' . $Frey::VERSION; +our $VERSION = '0.2'; +$VERSION .= " (Frey $Frey::VERSION)" if $Frey::VERSION; our $debug = $Frey::debug || 0; @@ -275,10 +275,13 @@ } $tx->res->code( $status ); - $tx->res->headers->content_type( 'text/json' ); + $tx->res->headers->content_type( 'text/plain;charset=utf-8' ); my $body = to_json $json; $tx->res->body( $body ); - warn "CouchDB API: $method $url $status $body\n"; + $tx->res->headers->add_line( 'Cache-Control' => 'must-revalidate' ); + $tx->res->headers->add_line( 'Server' => "Frey::CouchAPI/$VERSION" ); + + warn "INFO CouchDB API $method $url $status\n$body\n"; warn "## headers ", $tx->res->headers->to_string;