Kouhei Sutou
null+****@clear*****
Fri Jan 3 18:06:19 JST 2014
Kouhei Sutou 2014-01-03 18:06:19 +0900 (Fri, 03 Jan 2014) New Revision: 5f2fa13a28886a5b5a9f0a16fa951853c2a9785c https://github.com/ranguba/chupa-text/commit/5f2fa13a28886a5b5a9f0a16fa951853c2a9785c Message: Reuse one loader Modified files: lib/chupa-text/configuration-loader.rb Modified: lib/chupa-text/configuration-loader.rb (+2 -4) =================================================================== --- lib/chupa-text/configuration-loader.rb 2014-01-03 18:05:03 +0900 (b45a3f2) +++ lib/chupa-text/configuration-loader.rb 2014-01-03 18:06:19 +0900 (c6e79e6) @@ -18,8 +18,10 @@ require "chupa-text/configuration" module ChupaText class ConfigurationLoader + attr_reader :decomposer def initialize(configuration) @configuration = configuration + @decomposer = DecomposerLoader.new(@configuration.decomposer) @load_paths = [] data_dir = File.join(File.dirname(__FILE__), "..", "..", "data") @load_paths << File.expand_path(data_dir) @@ -32,10 +34,6 @@ module ChupaText end end - def decomposer - DecomposerLoader.new(@configuration.decomposer) - end - private def resolve_path(path) return path if File.exist?(path) -------------- next part -------------- HTML����������������������������... Download