From 795b8b4ade88a6fc57651cc2a8b13e3316a855f9 Mon Sep 17 00:00:00 2001 From: "Michael J. Rubinsky" Date: Fri, 31 Jul 2009 17:34:19 -0400 Subject: [PATCH] Make sure prototype is included from addExternal() as well, otherwise includeing an external script file before any other horde file would cause prototype.js to not be loaded. --- framework/Core/lib/Horde/Script/Files.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/framework/Core/lib/Horde/Script/Files.php b/framework/Core/lib/Horde/Script/Files.php index 934f9eb14..aeb75cb98 100644 --- a/framework/Core/lib/Horde/Script/Files.php +++ b/framework/Core/lib/Horde/Script/Files.php @@ -90,6 +90,11 @@ class Horde_Script_Files $this->_included[$app][$url] = true; + // Always add prototype.js. + if (empty($this->_files) && ($file != 'prototype.js')) { + $this->add('prototype.js', 'horde', true); + } + $this->_files[$app][] = array( 'f' => basename($url), 'u' => $url, -- 2.11.0