[prev in list] [next in list] [prev in thread] [next in thread] 

List:       bricolage-commits
Subject:    [8415] Files uploaded as images but without any suffix (such as
From:       theory () bricolage ! cc
Date:       2009-02-17 6:09:18
Message-ID: 20090217060919.867D5CB9AE () x12 ! develooper ! com
[Download RAW message or body]

Revision: 8415
Author:   theory
Date:     2009-02-16 22:09:18 -0800 (Mon, 16 Feb 2009)
ViewCVS:  http://viewsvn.bricolage.cc/?rev=8415&view=rev

Log Message:
-----------
Files uploaded as images but without any suffix (such as ".jpg") no longer
cause an error.

Modified Paths:
--------------
    bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm
    bricolage/branches/rev_1_10/lib/Bric/Changes.pod

Modified: bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm
===================================================================
--- bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm	2009-02-17 \
                05:41:56 UTC (rev 8414)
+++ bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm	2009-02-17 \
06:09:18 UTC (rev 8415) @@ -498,7 +498,7 @@
 sub _thumb_location {
     my $self = shift;
     my $loc = $self->get_location or return;
-    $loc =~ s/(\.[^.]+)$/_thumb$1/g or $loc .= '_thumb';
+    $loc =~ s{(\.[^.\\/]+)$}{_thumb$1}g or $loc .= '_thumb';
     return $loc;
 }
 

Modified: bricolage/branches/rev_1_10/lib/Bric/Changes.pod
===================================================================
--- bricolage/branches/rev_1_10/lib/Bric/Changes.pod	2009-02-17 05:41:56 UTC (rev \
                8414)
+++ bricolage/branches/rev_1_10/lib/Bric/Changes.pod	2009-02-17 06:09:18 UTC (rev \
8415) @@ -98,6 +98,11 @@
 for example, L</foo/bar> with L</foo_bar>. Reported by Scott (Bug # 1368).
 [David]
 
+=item *
+
+Files uploaded as images but without any suffix (such as ".jpg") no longer
+cause an error. Reported by Scott (Bug # 1409). [David]
+
 =back
 
 =head1 VERSION 1.10.6 (2008-10-02)


[Attachment #3 (text/html)]

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" /><style \
type="text/css"><!-- #msg dl { border: 1px #006 solid; background: #369; padding: \
6px; color: #fff; } #msg dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer { font-family: \
verdana,arial,helvetica,sans-serif; font-size: 10pt;  } #msg dl a { font-weight: \
bold} #msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: \
bold; } #msg pre { overflow: auto; background: #ffc; border: 1px #fc0 solid; padding: \
6px; } #msg ul, pre { overflow: auto; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: \
6px; } #patch { width: 100%; }
#patch h4 {font-family: \
verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
 #patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, \
#patch .copfile {border:1px solid #ccc;margin:10px 0;} #patch ins \
{background:#dfd;text-decoration:none;display:block;padding:0 10px;} #patch del \
{background:#fdd;text-decoration:none;display:block;padding:0 10px;} #patch .lines, \
                .info {color:#888;background:#fff;}
--></style>
<title>[8415] Files uploaded as images but without any suffix (such as \
&quot;.jpg&quot;)</title> </head>
<body>

<div id="msg">
<dl>
<dt>Revision</dt> <dd><a \
href="http://viewsvn.bricolage.cc/?rev=8415&amp;view=rev">8415</a></dd> \
<dt>Author</dt> <dd>theory</dd> <dt>Date</dt> <dd>2009-02-16 22:09:18 -0800 (Mon, 16 \
Feb 2009)</dd> </dl>

<h3>Log Message</h3>
<pre>Files uploaded as images but without any suffix (such as &quot;.jpg&quot;) no \
longer cause an error.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#bricolagebranchesrev_1_10libBricBizAssetBusinessMediaImagepm">bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm</a></li>
 <li><a href="#bricolagebranchesrev_1_10libBricChangespod">bricolage/branches/rev_1_10/lib/Bric/Changes.pod</a></li>
 </ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="bricolagebranchesrev_1_10libBricBizAssetBusinessMediaImagepm"></a>
<div class="modfile"><h4>Modified: \
bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm (8414 => \
8415)</h4> <pre class="diff"><span>
<span class="info">--- \
bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm	2009-02-17 \
                05:41:56 UTC (rev 8414)
+++ bricolage/branches/rev_1_10/lib/Bric/Biz/Asset/Business/Media/Image.pm	2009-02-17 \
06:09:18 UTC (rev 8415) </span><span class="lines">@@ -498,7 +498,7 @@
</span><span class="cx"> sub _thumb_location {
</span><span class="cx">     my $self = shift;
</span><span class="cx">     my $loc = $self-&gt;get_location or return;
</span><del>-    $loc =~ s/(\.[^.]+)$/_thumb$1/g or $loc .= '_thumb';
</del><ins>+    $loc =~ s{(\.[^.\\/]+)$}{_thumb$1}g or $loc .= '_thumb';
</ins><span class="cx">     return $loc;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="bricolagebranchesrev_1_10libBricChangespod"></a>
<div class="modfile"><h4>Modified: bricolage/branches/rev_1_10/lib/Bric/Changes.pod \
(8414 => 8415)</h4> <pre class="diff"><span>
<span class="info">--- bricolage/branches/rev_1_10/lib/Bric/Changes.pod	2009-02-17 \
                05:41:56 UTC (rev 8414)
+++ bricolage/branches/rev_1_10/lib/Bric/Changes.pod	2009-02-17 06:09:18 UTC (rev \
8415) </span><span class="lines">@@ -98,6 +98,11 @@
</span><span class="cx"> for example, L&lt;/foo/bar&gt; with L&lt;/foo_bar&gt;. \
Reported by Scott (Bug # 1368). </span><span class="cx"> [David]
</span><span class="cx"> 
</span><ins>+=item *
+
+Files uploaded as images but without any suffix (such as &quot;.jpg&quot;) no longer
+cause an error. Reported by Scott (Bug # 1409). [David]
+
</ins><span class="cx"> =back
</span><span class="cx"> 
</span><span class="cx"> =head1 VERSION 1.10.6 (2008-10-02)
</span></span></pre>
</div>
</div>

</body>
</html>



[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic