summaryrefslogtreecommitdiff
path: root/modules/g2_import/controllers/g2.php
diff options
context:
space:
mode:
authorMike Miller <github@mikeage.net>2013-02-01 15:33:18 +0200
committerMike Miller <github@mikeage.net>2013-02-01 15:36:49 +0200
commit6e757f9988545aa0afbf5b345f81cbfcc6bed7ab (patch)
tree9e63f09806fa045fb372436e5614bdbecb5cc6cc /modules/g2_import/controllers/g2.php
parent070095cf6cc628374ff56489c27220ca61b5735a (diff)
#1987 g2_import module should redirect with a 301, not 302
As the g2_import process is generally assumed to be permanent, the redirect should be a 301, and not a 302.
Diffstat (limited to 'modules/g2_import/controllers/g2.php')
-rw-r--r--modules/g2_import/controllers/g2.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/g2_import/controllers/g2.php b/modules/g2_import/controllers/g2.php
index 3641b342..c9b1d182 100644
--- a/modules/g2_import/controllers/g2.php
+++ b/modules/g2_import/controllers/g2.php
@@ -46,7 +46,7 @@ class G2_Controller extends Controller {
}
if (!$id) {
- url::redirect("tag_name/$tag_name");
+ url::redirect("tag_name/$tag_name", 301);
}
$tag = ORM::factory("tag")->where("name", "=", $tag_name)->find();
@@ -99,18 +99,18 @@ class G2_Controller extends Controller {
// Redirect the user to the new url
switch ($resource_type) {
case "thumbnail":
- url::redirect($item->thumb_url(true));
+ url::redirect($item->thumb_url(true), 301);
case "resize":
- url::redirect($item->resize_url(true));
+ url::redirect($item->resize_url(true), 301);
case "file":
case "full":
- url::redirect($item->file_url(true));
+ url::redirect($item->file_url(true), 301);
case "item":
case "album":
- url::redirect($item->abs_url());
+ url::redirect($item->abs_url(), 301);
case "group":
case "user":