Fix bug.
This commit is contained in:
parent
93c7fc6bfb
commit
3bebcaf7b1
|
@ -115,7 +115,7 @@ if bundle_update_flag
|
||||||
default_announcement_widget_info.each do |h|
|
default_announcement_widget_info.each do |h|
|
||||||
name_without_index = h["name"]["zh_tw"].sub(/\d+/,'')
|
name_without_index = h["name"]["zh_tw"].sub(/\d+/,'')
|
||||||
widget_info_index = (widget_info.index{|hh| hh["name"]["zh_tw"].include?(name_without_index)} rescue -1)
|
widget_info_index = (widget_info.index{|hh| hh["name"]["zh_tw"].include?(name_without_index)} rescue -1)
|
||||||
if widget_info_index == -1
|
if (widget_info_index == -1 || widget_info_index.nil?)
|
||||||
update_flag = true
|
update_flag = true
|
||||||
copy_h = h.dup
|
copy_h = h.dup
|
||||||
h.delete("force_cover")
|
h.delete("force_cover")
|
||||||
|
|
Loading…
Reference in New Issue