[Slashdotjp-dev 1145] [672] Fix: redirect url when ('?m=1') has been appended

Zurück zum Archiv-Index

svnno****@sourc***** svnno****@sourc*****
2008年 6月 23日 (月) 13:05:40 JST


Revision: 672
          http://svn.sourceforge.jp/cgi-bin/viewcvs.cgi?root=slashdotjp&view=rev&rev=672
Author:   tach
Date:     2008-06-23 13:05:40 +0900 (Mon, 23 Jun 2008)

Log Message:
-----------
Fix: redirect url when ('?m=1') has been appended

Modified Paths:
--------------
    slashjp/branches/2.5.0.192/Slash/Utility/Data/Data.pm
    slashjp/branches/2.5.0.192/debian/changelog


-------------- next part --------------
Modified: slashjp/branches/2.5.0.192/Slash/Utility/Data/Data.pm
===================================================================
--- slashjp/branches/2.5.0.192/Slash/Utility/Data/Data.pm	2008-06-20 13:09:33 UTC (rev 671)
+++ slashjp/branches/2.5.0.192/Slash/Utility/Data/Data.pm	2008-06-23 04:05:40 UTC (rev 672)
@@ -414,12 +414,15 @@
 sub cleanRedirectUrl {
 	my($redirect) = @_;
 	my $gSkin = getCurrentSkin();
+	my $form = getCurrentForm();
+	my $rurl = $gSkin->{rootdir};
+	$rurl .= '?m=1' if ($form->{m});
 
 	if (urlFromSite($redirect)) {
 		my $base = root2abs();
-		return URI->new_abs($redirect || $gSkin->{rootdir}, $base);
+		return URI->new_abs($redirect || $rurl, $base);
 	} else {
-		return url2abs($gSkin->{rootdir});
+		return url2abs($rurl);
 	}
 }
 

Modified: slashjp/branches/2.5.0.192/debian/changelog
===================================================================
--- slashjp/branches/2.5.0.192/debian/changelog	2008-06-20 13:09:33 UTC (rev 671)
+++ slashjp/branches/2.5.0.192/debian/changelog	2008-06-23 04:05:40 UTC (rev 672)
@@ -6,8 +6,9 @@
     - commentsort = mobile_commentsort
     - commentlimit = mobile_commentlimit
     - mode = mobile_commentmode
+  * Fix: redirect url when ('?m=1') has been appended
 
- -- Taku YASUI <tach****@osdn*****>  Fri, 20 Jun 2008 13:06:35 +0000
+ -- Taku YASUI <tach****@osdn*****>  Mon, 23 Jun 2008 04:04:52 +0000
 
 slash (2.5.0.192-13) unstable; urgency=low
 


Slashdotjp-dev メーリングリストの案内
Zurück zum Archiv-Index