diff --git a/app/controllers/announcements_controller.rb b/app/controllers/announcements_controller.rb index 10b162c..3b301f2 100644 --- a/app/controllers/announcements_controller.rb +++ b/app/controllers/announcements_controller.rb @@ -46,7 +46,7 @@ class AnnouncementsController < ApplicationController page = @page || Page.where(url: params['url']).first @enable_search_flag = false @image_version = 'thumb' - if page.methods.include? 'select_option_items'.to_sym + if page.respond_to?(:select_option_items) ModuleApp.all.select{|tmp| tmp.key.to_s=='announcement'}.each do |modile_app| @show_option_items = modile_app.show_option_items rescue nil end