From 01c39cf2bea11d6ebfb7c5abf60d5c6878dc3ad0 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Thomas=20M=C3=BCller?= Date: Wed, 17 Jul 2013 23:27:25 +0200 Subject: [PATCH] fixing typos, PHPDoc and missing namespace \ --- lib/template.php | 10 +++++----- lib/template/cssresourcelocator.php | 4 ++-- lib/template/jsresourcelocator.php | 6 +++--- lib/template/templatefilelocator.php | 1 + 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/lib/template.php b/lib/template.php index fc3c6b6d54f..646d9b11235 100644 --- a/lib/template.php +++ b/lib/template.php @@ -24,7 +24,7 @@ require_once __DIR__.'/template/functions.php'; /** - * This class provides the templates for owncloud. + * This class provides the templates for ownCloud. */ class OC_Template extends \OC\Template\Base { private $renderas; // Create a full page? @@ -34,7 +34,7 @@ class OC_Template extends \OC\Template\Base { /** * @brief Constructor * @param string $app app providing the template - * @param string $file name of the template file (without suffix) + * @param string $name of the template file (without suffix) * @param string $renderas = ""; produce a full page * @return OC_Template object * @@ -172,7 +172,7 @@ class OC_Template extends \OC\Template\Base { /** * @brief Add a custom element to the header * @param string $tag tag name of the element - * @param array $attributes array of attrobutes for the element + * @param array $attributes array of attributes for the element * @param string $text the text content for the element */ public function addHeader( $tag, $attributes, $text='') { @@ -264,8 +264,8 @@ class OC_Template extends \OC\Template\Base { /** * @brief Print a fatal error page and terminates the script - * @param string $error The error message to show - * @param string $hint An optional hint message + * @param string $error_msg The error message to show + * @param string $hint An optional hint message * Warning: All data passed to $hint needs to get sanitized using OC_Util::sanitizeHTML */ public static function printErrorPage( $error_msg, $hint = '' ) { diff --git a/lib/template/cssresourcelocator.php b/lib/template/cssresourcelocator.php index e27296d9f5f..8e7831ca549 100644 --- a/lib/template/cssresourcelocator.php +++ b/lib/template/cssresourcelocator.php @@ -21,10 +21,10 @@ class CSSResourceLocator extends ResourceLocator { } $app = substr($style, 0, strpos($style, '/')); $style = substr($style, strpos($style, '/')+1); - $app_path = OC_App::getAppPath($app); + $app_path = \OC_App::getAppPath($app); $app_url = $this->webroot . '/index.php/apps/' . $app; if ($this->appendIfExist($app_path, $style.$this->form_factor.'.css', $app_url) - || $this->appendIfExist($app_path, $style.'.css', $ap_url) + || $this->appendIfExist($app_path, $style.'.css', $app_url) ) { return; } diff --git a/lib/template/jsresourcelocator.php b/lib/template/jsresourcelocator.php index a1382edf2d5..f8fe3817ce6 100644 --- a/lib/template/jsresourcelocator.php +++ b/lib/template/jsresourcelocator.php @@ -28,10 +28,10 @@ class JSResourceLocator extends ResourceLocator { } $app = substr($script, 0, strpos($script, '/')); $script = substr($script, strpos($script, '/')+1); - $app_path = OC_App::getAppPath($app); - $app_url = OC_App::getAppWebPath($app); + $app_path = \OC_App::getAppPath($app); + $app_url = \OC_App::getAppWebPath($app); if ($this->appendIfExist($app_path, $script.$this->form_factor.'.js', $app_url) - || $this->appendIfExist($app_path, $script.'.js', $ap_url) + || $this->appendIfExist($app_path, $script.'.js', $app_url) ) { return; } diff --git a/lib/template/templatefilelocator.php b/lib/template/templatefilelocator.php index eeb27c139a7..cc5e88771ff 100644 --- a/lib/template/templatefilelocator.php +++ b/lib/template/templatefilelocator.php @@ -11,6 +11,7 @@ namespace OC\Template; class TemplateFileLocator { protected $form_factor; protected $dirs; + private $path; public function __construct( $form_factor, $dirs ) { $this->form_factor = $form_factor; -- 2.39.5