]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Removing legacy code and fixup_* for Status_network tags
authorMikael Nordfeldth <mmn@hethane.se>
Tue, 15 Oct 2013 08:54:03 +0000 (10:54 +0200)
committerMikael Nordfeldth <mmn@hethane.se>
Tue, 15 Oct 2013 08:54:03 +0000 (10:54 +0200)
classes/Status_network.php
scripts/fixup_status_network.php [deleted file]

index 7d6e9461136dbbb007b03f9de5a24ab8098e4002..eb9bd69e1f94f1db07fbf3e89c88c1d8ede5b0f9 100644 (file)
@@ -318,14 +318,7 @@ class Status_network extends Safe_DataObject
      */
     function getTags()
     {
-        $result = Status_network_tag::getTags($this->site_id);
-
-        // XXX : for backwards compatibility
-        if (empty($result)) {
-            return explode('|', $this->tags);
-        }
-
-        return $result;
+        return Status_network_tag::getTags($this->site_id);
     }
 
     /**
diff --git a/scripts/fixup_status_network.php b/scripts/fixup_status_network.php
deleted file mode 100644 (file)
index def1eaa..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-#!/usr/bin/env php
-<?php
-/*
- * StatusNet - the distributed open-source microblogging tool
- * Copyright (C) 2008, 2009, StatusNet, Inc.
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Affero General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU Affero General Public License for more details.
- *
- * You should have received a copy of the GNU Affero General Public License
- * along with this program.  If not, see <http://www.gnu.org/licenses/>.
- */
-
-define('INSTALLDIR', realpath(dirname(__FILE__) . '/..'));
-
-require_once INSTALLDIR.'/scripts/commandline.inc';
-
-common_log(LOG_INFO, 'Beginning status_network conversion...');
-
-$sn = new Status_network();
-$sn->find();
-while ($sn->fetch()) {
-    try {
-        $sn->setTags(explode('|', $sn->tags));
-    } catch (Exception $e) {
-        common_log(LOG_ERR, $e->getMessage());
-    }
-}
-
-common_log(LOG_INFO, 'Completed status_network conversion...');