[Jifty-commit] jifty branch, plack-rebased, updated. a490aa30d877369121f56a6dc5d6f2edbafebd8f

Jifty commits jifty-commit at lists.jifty.org
Sun Feb 7 09:16:51 EST 2010


The branch, plack-rebased has been updated
       via  a490aa30d877369121f56a6dc5d6f2edbafebd8f (commit)
      from  769c800f02ae49a850c4171f6a5fe69af5ce0b55 (commit)

Summary of changes:
 lib/Jifty/Plugin/Compat.pm |   13 +++++++++++++
 1 files changed, 13 insertions(+), 0 deletions(-)

- Log -----------------------------------------------------------------
commit a490aa30d877369121f56a6dc5d6f2edbafebd8f
Author: Chia-liang Kao <clkao at clkao.org>
Date:   Sun Feb 7 22:16:41 2010 +0800

    Provide headers_in, headers_out and uri methods for compat plugin apache.

diff --git a/lib/Jifty/Plugin/Compat.pm b/lib/Jifty/Plugin/Compat.pm
index dc67041..78f8021 100644
--- a/lib/Jifty/Plugin/Compat.pm
+++ b/lib/Jifty/Plugin/Compat.pm
@@ -92,6 +92,10 @@ sub header_in {
     return Jifty->web->request->header(@_);
 }
 
+sub headers_in {
+    return Jifty->web->request->headers;
+}
+
 sub header_out {
     my ($class, $key, $val) = @_;
     if ($key eq 'Status') {
@@ -111,6 +115,15 @@ sub header_out {
     Jifty->web->response->header( $key, $val );
 }
 
+sub headers_out {
+    return Jifty->web->response->headers;
+}
+
+sub uri {
+    my $req = Jifty->web->request;
+    return $req->script_name . $req->path_info || '';
+}
+
 sub method {
     Jifty->web->request->method;
 }

-----------------------------------------------------------------------


More information about the Jifty-commit mailing list