[logaling-commit] logaling/logaling-command [import-tmx] change 'note' to 'notes'

Back to archive index

null+****@clear***** null+****@clear*****
Fri Apr 27 18:10:10 JST 2012


SUZUKI Miho	2012-04-27 18:10:10 +0900 (Fri, 27 Apr 2012)

  New Revision: 8247399a3cf65074a23ee3826f1b98424b3229a9

  Log:
    change 'note' to 'notes'

  Modified files:
    lib/logaling/external_glossaries/tmx.rb

  Modified: lib/logaling/external_glossaries/tmx.rb (+4 -4)
===================================================================
--- lib/logaling/external_glossaries/tmx.rb    2012-04-27 17:37:32 +0900 (333dbcf)
+++ lib/logaling/external_glossaries/tmx.rb    2012-04-27 18:10:10 +0900 (02ac5ba)
@@ -28,7 +28,7 @@ module Logaling
       doc.search('//tu').each do |tu|
         original = ""
         translation = ""
-        note = []
+        notes = []
         tu.children.each do |tuv|
           if tuv.name == "tuv"
             # logaling using ISO 639 codes (two-letter)
@@ -36,17 +36,17 @@ module Logaling
             if lang == glossary_info[:source_language]
               tuv.children.each do |child|
                 original = child.text.strip if child.name == "seg"
-                note << child.text.strip if child.name == "note"
+                notes << child.text.strip if child.name == "note"
               end
             elsif lang == glossary_info[:target_language]
               tuv.children.each do |child|
                 translation = child.text.strip if child.name == "seg"
-                note << child.text.strip if child.name == "note"
+                notes << child.text.strip if child.name == "note"
               end
             end
           end
         end
-        csv << [original, translation, note.join(" | ")] if original && translation
+        csv << [original, translation, notes.join(" | ")] if original && translation
       end
     end
   end




More information about the logaling-commit mailing list
Back to archive index