Skip Menu |

This queue is for tickets about the Catalyst-Runtime CPAN distribution.

Report information
The Basics
Id: 46276
Status: resolved
Priority: 0/
Queue: Catalyst-Runtime

People
Owner: bobtfish [...] bobtfish.net
Requestors: kmx [...] volny.cz
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: [PATCH] fix for accessing $c->engine->env->{VARNAME}
Date: Thu, 21 May 2009 17:12:17 +0200
To: bug-Catalyst-Runtime [...] rt.cpan.org
From: kmx <kmx [...] volny.cz>
Hi, I have found out that accessing env vars through $c->engine->env->{VARNAME} does not work despite the fact that many people on IRC was sure it does. After some investigation I have found out that line "has env => (is => 'rw');" was probably by mistake added to Catalyst::Engine::CGI not to its parent Catalyst::Engine. I am sending patch for this. It could be also fine to drop a line in doc that something like $c->engine->env->{VARNAME} is available. -- kmx --- Catalyst/Engine/CGI.orig +++ Catalyst/Engine/CGI.pm @@ -3,7 +3,6 @@ use Moose; extends 'Catalyst::Engine'; -has env => (is => 'rw'); has _header_buf => (is => 'rw', clearer => '_clear_header_buf', predicate => '_has_header_buf'); =head1 NAME --- Catalyst/Engine.orig +++ Catalyst/Engine.pm @@ -13,6 +13,8 @@ use namespace::clean -except => 'meta'; +has env => (is => 'rw'); + # input position and length has read_length => (is => 'rw'); has read_position => (is => 'rw');
This patch + docs was applied. I'm guessing that you're happy with this, and the issue will be fixed in 5.80005, so I'm going to close this ticket. Many thanks once again :)