~mdw
/
tgal
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
mason/.perl-lib/TrivGal.pm (Image::scale): Return encoded URL.
[tgal]
/
mason
/
.perl-lib
/
TrivGal.pm
diff --git
a/mason/.perl-lib/TrivGal.pm
b/mason/.perl-lib/TrivGal.pm
index
600e9f5
..
eadb8c3
100644
(file)
--- a/
mason/.perl-lib/TrivGal.pm
+++ b/
mason/.perl-lib/TrivGal.pm
@@
-219,11
+219,13
@@
package TrivGal::Image {
sub scale ($$) {
my ($me, $scale) = @_;
sub scale ($$) {
my ($me, $scale) = @_;
+ my $m = HTML::Mason::Request->instance;
my $path = $me->{path};
my $sz = $SIZE{$scale} or die "unknown scale `$scale'";
my $thumb = "$CACHE/scale.$sz/$path";
my $path = $me->{path};
my $sz = $SIZE{$scale} or die "unknown scale `$scale'";
my $thumb = "$CACHE/scale.$sz/$path";
- my $thumburl = "$CACHEURL/scale.$sz/$path";
+ my $thumburl =
+ $m->interp->apply_escapes("$CACHEURL/scale.$sz/$path", "u");
my $st = stat $thumb;
if (defined $st && $st->mtime > $me->{mtime}) { return $thumburl; }
my $st = stat $thumb;
if (defined $st && $st->mtime > $me->{mtime}) { return $thumburl; }