strings are generated from module.txt only

May 28, 2011 at 10:16 AM

Hi, I've tried to use "extract default translation" (example follows) command provided by the module and it extracted strings from the module.txt only. 

orchard> extract default translation /Extensions:Contrib.Taxonomies /Output:C:\T
emp\taxonomies

So I looked in the source code and problem seems to be in Vandelay.TranslationManager.Services.LocalizationManagementService class on line 113:

return new[] {"themes", "modules"}.Contains(tokens[0]) &&
                           extensionNames.Contains(tokens[1]);

I noticed that strings in tokens have first letter upper cased.  When I changed "modules" to "Modules" all strings was generated correctly so it's look like minor problem with case sensitivity.

Anyway, thank you for all your work on this module.

Jan Chvojka

 

Jun 1, 2011 at 10:40 AM

I would change it to

return new[] {"themes", "modules"}.Contains(tokens[0], StringComparer.OrdinalIgnoreCase) &&

Jun 1, 2011 at 1:54 PM

Thanks, it's definitely much more elegant solution.

Nov 21, 2013 at 12:21 PM
Fascinating: This module is referenced by the official Orchard documentation and the owner is the supervisor of Orchard -- but nothing happens for years.