]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Move NOTICES_PER_MAP to SitemapPlugin
authorEvan Prodromou <evan@status.net>
Mon, 12 Apr 2010 14:23:32 +0000 (10:23 -0400)
committerEvan Prodromou <evan@status.net>
Wed, 28 Apr 2010 22:41:27 +0000 (18:41 -0400)
plugins/Sitemap/SitemapPlugin.php
plugins/Sitemap/noticesitemap.php

index 5b2af487959c736cb64ec15e3816096e96c11c13..fa9c9a76d08355368b30f44f6c954bbb19442615 100644 (file)
@@ -47,7 +47,8 @@ if (!defined('STATUSNET')) {
 
 class SitemapPlugin extends Plugin
 {
-    const USERS_PER_MAP = 25000;
+    const USERS_PER_MAP   = 25000;
+    const NOTICES_PER_MAP = 25000;
 
     /**
      * Load related modules when needed
index 12a22dbb22a6e40201272594058ea7b0c8d8e2d6..c8db24efee73d09156b3faeec03c3ae9ff3b8aa6 100644 (file)
@@ -43,8 +43,6 @@ if (!defined('STATUSNET')) {
 
 class NoticesitemapAction extends SitemapAction
 {
-    const NOTICES_PER_MAP = 25000;
-
     var $notice = null;
 
     function prepare($args)
@@ -63,8 +61,8 @@ class NoticesitemapAction extends SitemapAction
         $d += 0;
         $i += 0;
 
-        $offset = ($i-1) * self::NOTICES_PER_MAP;
-        $limit  = self::NOTICES_PER_MAP;
+        $offset = ($i-1) * SitemapPlugin::NOTICES_PER_MAP;
+        $limit  = SitemapPlugin::NOTICES_PER_MAP;
 
         $this->notice = new Notice();