[logaling-commit] logaling/logaling-command [refactor-structure] Set glossary only if received glossary option

Back to archive index

null+****@clear***** null+****@clear*****
Mon Jun 25 11:34:47 JST 2012


SHIMADA Koji	2012-06-25 11:34:47 +0900 (Mon, 25 Jun 2012)

  New Revision: 6c73e4ad5c0ea86fa9e8a997d9aacce5241501b6
  https://github.com/logaling/logaling-command/commit/6c73e4ad5c0ea86fa9e8a997d9aacce5241501b6

  Log:
    Set glossary only if received glossary option

  Modified files:
    lib/logaling/command/application.rb

  Modified: lib/logaling/command/application.rb (+6 -2)
===================================================================
--- lib/logaling/command/application.rb    2012-06-22 20:18:04 +0900 (54bba26)
+++ lib/logaling/command/application.rb    2012-06-25 11:34:47 +0900 (c4a6000)
@@ -241,8 +241,12 @@ module Logaling::Command
     def lookup(source_term)
       check_logaling_home_exists
       @repository.index
-      project =****@repos*****_project(@config.glossary)
-      glossary = project.find_glossary(@config.source_language, @config.target_language)
+      if****@confi*****
+        project =****@repos*****_project(@config.glossary)
+        glossary = project.find_glossary(@config.source_language, @config.target_language)
+      else
+        glossary = nil
+      end
       terms =****@repos*****(source_term, glossary, options["dictionary"])
       unless terms.empty?
         max_str_size = terms.map{|term| term[:source_term].size}.sort.last
-------------- next part --------------
An HTML attachment was scrubbed...
下載 



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