This commit is contained in:
BOHUNG 2020-04-01 17:36:00 +08:00
parent bae12a5ac4
commit ca500a936e
1 changed files with 1 additions and 1 deletions

View File

@ -81,7 +81,7 @@ begin
if @file_text.include?(change_html_old) if @file_text.include?(change_html_old)
@file_text = @file_text.gsub(change_html_old,change_html_new) @file_text = @file_text.gsub(change_html_old,change_html_new)
@f.write(@file_text) @f.write(@file_text)
elsif !@file_text.include?(change_html_old) && !@file_text.include?(change_html_new) elsif (!@file_text.include?(change_html_old) && !@file_text.include?(change_html_new))
insert_index = @file_text.index('html.gsub("%7B%7Blogo_url%7D%7D"') insert_index = @file_text.index('html.gsub("%7B%7Blogo_url%7D%7D"')
@file_text.insert(insert_index,change_html_new+"\n") @file_text.insert(insert_index,change_html_new+"\n")
@f.write(@file_text) @f.write(@file_text)