Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

MINOR Workaround for duplicate require_once calls of same class in tw…

…o locations (SS core and Zend_Translate_RailsYAML)
  • Loading branch information...
commit c649fa3acfcdc5a341f3a9e43f0bdfb4eaddd31e 1 parent d3b63da
@chillu chillu authored
View
1  i18n/i18nTextCollector.php
@@ -481,6 +481,7 @@ public function write($entities, $locale, $path) {
}
public function getYaml($entities, $locale) {
+ // Check required because Zend_Translate_RailsYAML also includes the lib, from a different location
if(!class_exists('sfYamlDumper', false)) require_once 'thirdparty/symfony-yaml/lib/sfYamlDumper.php';
// Unflatten array
View
6 thirdparty/zend_translate_railsyaml/library/Translate/Adapter/RailsYAML.php
@@ -6,7 +6,11 @@
/** Zend_Translate_Adapter */
require_once 'Zend/Translate/Adapter.php';
-// require_once 'thirdparty/sfYaml/lib/sfYaml.php';
+// ischommer CUSTOM Check required because SS core also includes the lib, from a different location
+if(!class_exists('sfYaml')) require_once 'thirdparty/sfYaml/lib/sfYaml.php';
+if(!class_exists('sfYamlParser')) require_once 'thirdparty/sfYaml/lib/sfYamlParser.php';
+if(!class_exists('sfYamlDumper')) require_once 'thirdparty/sfYaml/lib/sfYamlDumper.php';
+// ischommer END_CUSTOM
class Translate_Adapter_RailsYaml extends Zend_Translate_Adapter {
Please sign in to comment.
Something went wrong with that request. Please try again.