This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "quickfw".
The branch, master has been updated
via ccd4b3c9746fbe737107664270f7e0475f3ba3e1 (commit)
from 627ae4c38d52c27683a3658f5ad41f79dc121a5a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit ccd4b3c9746fbe737107664270f7e0475f3ba3e1
Author: Ivan Borzenkov <iva...@li...>
Date: Tue Apr 12 18:44:52 2011 +0400
Удалил дублирование кода
diff --git a/lib/Sitemap.php b/lib/Sitemap.php
index d2cf104..b16100a 100644
--- a/lib/Sitemap.php
+++ b/lib/Sitemap.php
@@ -62,12 +62,9 @@ class Sitemap
//Файл был не один - генерим индекс
if ($this->curFileNum)
{
+ //если у нас еще есть урлы для записи
if ($this->last_urls != 50000)
- { //если у нас еще есть урлы для записи
- $this->curFileNum++;
- file_put_contents(($this->gzip ? 'compress.zlib://' : '').
- $this->dir.'/'.$this->name.$this->curFileNum.'.'.($this->gzip ? 'gz' : 'xml'), $this->data.$this->foot);
- }
+ $this->nextFile();
$index= '<?xml version="1.0" encoding="UTF-8"?>'."\n".
'<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">'."\n";
-----------------------------------------------------------------------
Summary of changes:
lib/Sitemap.php | 7 ++-----
1 files changed, 2 insertions(+), 5 deletions(-)
hooks/post-receive
--
quickfw
|