Permalink
Browse files

MINOR reverted changes to i18nTextCollector, and updated documentation

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@91211 467b73ca-7a2a-4603-9d3b-597d59a354a9
  • Loading branch information...
1 parent 0526124 commit 94b0ab581e8762aed6290e0e99a11f89460a4e82 @rixth rixth committed Nov 10, 2009
Showing with 11 additions and 11 deletions.
  1. +11 −11 core/i18nTextCollector.php
View
@@ -13,10 +13,10 @@
* The collector needs to be run whenever you make new translatable
* entities available. Please don't alter the arrays in language tables manually.
*
- * Usage through URL: http://localhost/dev/tasks/i18nTextCollector
- * Usage through URL (module-specific): http://localhost/dev/tasks/i18nTextCollector/?module=mymodule
- * Usage on CLI: sake dev/tasks/i18nTextCollector
- * Usage on CLI (module-specific): sake dev/tasks/i18nTextCollector module=mymodule
+ * Usage through URL: http://localhost/dev/tasks/i18nTextCollectorTast
+ * Usage through URL (module-specific): http://localhost/dev/tasks/i18nTextCollectorTask/?module=mymodule
+ * Usage on CLI: sake dev/tasks/i18nTextCollectorTask
+ * Usage on CLI (module-specific): sake dev/tasks/i18nTextCollectorTask module=mymodule
*
* Requires PHP 5.1+ due to class_implements() limitations
*
@@ -27,7 +27,7 @@
* @uses i18nEntityProvider
* @uses i18n
*/
-class i18nTextCollector extends BuildTask {
+class i18nTextCollector extends Object {
protected $defaultLocale;
@@ -75,13 +75,13 @@ public function run($restrictToModules = null) {
$entitiesByModule = array();
//Search for and process existent modules, or use the passed one instead
- // if($restrictToModules && count($restrictToModules)) {
- // foreach($restrictToModules as $restrictToModule) {
- // $modules[] = basename($restrictToModule);
- // }
- // } else {
+ if($restrictToModules && count($restrictToModules)) {
+ foreach($restrictToModules as $restrictToModule) {
+ $modules[] = basename($restrictToModule);
+ }
+ } else {
$modules = scandir($this->basePath);
- // }
+ }
foreach($modules as $module) {
// Only search for calls in folder with a _config.php file (which means they are modules)

0 comments on commit 94b0ab5

Please sign in to comment.