Re-add some require statements for libraries that can't be autoloaded
authorMichael J. Rubinsky <mrubinsk@horde.org>
Fri, 31 Jul 2009 19:42:08 +0000 (15:42 -0400)
committerMichael J. Rubinsky <mrubinsk@horde.org>
Fri, 31 Jul 2009 19:42:08 +0000 (15:42 -0400)
yet.

ansel/lib/Ansel.php
ansel/lib/Form/Ecard.php
ansel/lib/Report.php
ansel/lib/View/List.php
ansel/rss.php

index de061d3..6da32da 100644 (file)
@@ -6,6 +6,12 @@
  * did not receive this file, see http://www.fsf.org/copyleft/gpl.html.
  */
 
+/** Horde_Share */
+require_once 'Horde/Share.php';
+
+/** Need to bring this in explicitly since we extend the object class */
+require_once 'Horde/Share/sql_hierarchical.php';
+
 /**
  * Ansel Base Class.
  *
@@ -1477,6 +1483,7 @@ class Ansel_Gallery extends Horde_Share_Object_sql_hierarchical {
      */
     function getOwner()
     {
+        require_once 'Horde/Identity.php';
         $identity = Identity::singleton('none', $this->data['share_owner']);
         return $identity;
     }
@@ -2835,6 +2842,7 @@ class Ansel_Image {
         }
 
         if (empty($watermark)) {
+            require_once 'Horde/Identity.php';
             $identity = Identity::singleton();
             $name = $identity->getValue('fullname');
             if (empty($name)) {
index ebcb478..bf50f3f 100644 (file)
@@ -23,6 +23,7 @@ class Ansel_Form_Ecard extends Horde_Form {
         if (empty($user)) {
             $this->addVariable(_("Use the following return address:"), 'ecard_retaddr', 'text', true);
         } else {
+            require_once 'Horde/Identity.php';
             $identity = Identity::singleton();
             $from_addr = $identity->getDefaultFromAddress();
             $vars->set('ecard_retaddr', $from_addr);
index cb6a022..7a49173 100644 (file)
@@ -56,6 +56,7 @@ class Ansel_Report {
     function _getUserEmail($user = null)
     {
         // Get user email
+        require_once 'Horde/Identity.php';
         $identity = Identity::singleton('none', $user);
         return $identity->getValue('from_addr');
     }
index aea0364..b6a6c51 100644 (file)
@@ -133,6 +133,7 @@ class Ansel_View_List extends Ansel_View_Base
                                                 'ansel', $owner, '', null, false);
                     $fullname = $uprefs->getValue('grouptitle');
                     if (!$fullname) {
+                        require_once 'Horde/Identity.php';
                         $identity = &Identity::singleton('none', $owner);
                         $fullname = $identity->getValue('fullname');
                         if (!$fullname) {
index 4d7b1d6..5f0670d 100644 (file)
@@ -140,6 +140,7 @@ if (empty($rss)) {
         if (isset($galleries) && count($galleries)) {
             $images = $ansel_storage->getRecentImages($galleries);
             if (!is_a($images, 'PEAR_Error') && count($images)) {
+                require_once 'Horde/Identity.php';
                 $owner = Identity::singleton('none', $id);
                 $name = $owner->getValue('fullname');
                 $author = $owner->getValue('from_addr');