From 4902c2f773824c5127da141132a4f8d901a7d2f8 Mon Sep 17 00:00:00 2001 From: Chuck Hagenbuch Date: Fri, 20 Nov 2009 20:11:15 -0500 Subject: [PATCH] remove extra array from api call --- ansel/lib/Widget/Actions.php | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/ansel/lib/Widget/Actions.php b/ansel/lib/Widget/Actions.php index 05f536332..4cf72d92c 100644 --- a/ansel/lib/Widget/Actions.php +++ b/ansel/lib/Widget/Actions.php @@ -7,8 +7,14 @@ */ class Ansel_Widget_Actions extends Ansel_Widget_Base { + /** + * @var string + */ protected $_supported_views = array('Gallery'); + /** + * @param array $params + */ public function __construct($params) { $this->_title = _("Gallery Actions"); @@ -79,11 +85,11 @@ class Ansel_Widget_Actions extends Ansel_Widget_Base return $html; } - /** - * Helper function for generating the gallery actions selection widget. - * - * @return string The HTML - */ + /** + * Helper function for generating the gallery actions selection widget. + * + * @return string The HTML + */ protected function _getGalleryActions() { global $registry, $conf; @@ -118,12 +124,12 @@ class Ansel_Widget_Actions extends Ansel_Widget_Base /* Bookmark link */ if ($registry->hasMethod('bookmarks/getAddUrl')) { - $api_params = array( + $api_params = array( 'url' => Ansel::getUrlFor('view', $view_params, true), 'title' => $this->_view->gallery->get('name')); try { - $url = $registry->bookmarks->getAddUrl(array($api_params)); + $url = $registry->bookmarks->getAddUrl($api_params); } catch (Horde_Exception $e) {} $html .= '
  • ' . Horde::link($url, '', 'widget') . Horde::img('trean.png', '', '', $registry->getImageDir('trean')) . ' ' . _("Add to bookmarks") . '
  • '; @@ -193,5 +199,4 @@ class Ansel_Widget_Actions extends Ansel_Widget_Base return $html; } - } -- 2.11.0