[Dancer-users] Conditional HTTP proposal

Richard Huxton dev at archonet.com
Fri Feb 11 13:38:21 CET 2011


On 10/02/11 17:36, Oleg A. Mamontov wrote:
> +        my $lmod = strftime '%a, %d %b %Y %H:%M:%S GMT', gmtime(stat($fh)->mtime);
> +        my $imod = Dancer::SharedData->request->header('If-Modified-Since') || '';
> +
> +        Dancer::Response->status( $lmod eq $imod ? 304 : $status );
...
> +        Dancer::Response::set_current_content($fh) unless $lmod eq $imod;

Should this not be "ge" rather than "eq"?

-- 
   Richard Huxton
   Archonet Ltd


More information about the Dancer-users mailing list