From f31e286f4a73c5c0f355512b0cb45c6c82088516 Mon Sep 17 00:00:00 2001 From: Ralph Amissah Date: Sat, 22 Jun 2013 01:13:46 -0400 Subject: v5: general code cleaning * propagate back to v4 after testing --- lib/sisu/v5/shared_txt.rb | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'lib/sisu/v5/shared_txt.rb') diff --git a/lib/sisu/v5/shared_txt.rb b/lib/sisu/v5/shared_txt.rb index 3401b05b..8e8e7edb 100644 --- a/lib/sisu/v5/shared_txt.rb +++ b/lib/sisu/v5/shared_txt.rb @@ -132,7 +132,7 @@ module SiSU_TextUtils @md,@p=md,para end def extract(tag,tag_content,type,attrib) - dc=if dc_tag \ + if dc_tag \ and dc_content [dc_tag,dc_content,{dc_tag=>dc_content}] else nil @@ -167,7 +167,7 @@ module SiSU_TextUtils self end def start_is_match - meta=case @p + case @p when /^#{Mx[:meta_o]}(title)#{Mx[:meta_c]}\s*(.+?)$/; header($1,@md.title.full,'meta','dc') #dc 1 when /^#{Mx[:meta_o]}(creator|author)#{Mx[:meta_c]}\s*(.+?)$/; header('creator',$2,'meta','dc') #dc 2 when /^#{Mx[:meta_o]}(subject)#{Mx[:meta_c]}\s*(.+?)$/; header($1,$2,'meta','dc') #dc 3 @@ -218,13 +218,13 @@ module SiSU_TextUtils end end def dublin - out=if @p =~/^#{Mx[:meta_o]}\S+?#{Mx[:meta_c]}/ + if @p =~/^#{Mx[:meta_o]}\S+?#{Mx[:meta_c]}/ start_is_match else nil end end def meta - out=if @p =~/^#{Mx[:meta_o]}\S+?#{Mx[:meta_c]}/ + if @p =~/^#{Mx[:meta_o]}\S+?#{Mx[:meta_c]}/ start_is_match else nil end -- cgit v1.2.3