From ac88ea98e9506f0a668ad612e83f4b0e69382219 Mon Sep 17 00:00:00 2001 From: rgarcia Date: Tue, 29 Sep 2015 11:58:29 +0200 Subject: [PATCH] fixes typo --- app/controllers/concerns/flag_actions.rb | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/controllers/concerns/flag_actions.rb b/app/controllers/concerns/flag_actions.rb index ef7ccb3af..6bb0b61d6 100644 --- a/app/controllers/concerns/flag_actions.rb +++ b/app/controllers/concerns/flag_actions.rb @@ -2,18 +2,18 @@ module FlagActions extend ActiveSupport::Concern def flag - Flag.flag(current_user, flagable) - respond_with flagable, template: "#{controller_name}/_refresh_flag_actions" + Flag.flag(current_user, flaggable) + respond_with flaggable, template: "#{controller_name}/_refresh_flag_actions" end def unflag - Flag.unflag(current_user, flagable) - respond_with flagable, template: "#{controller_name}/_refresh_flag_actions" + Flag.unflag(current_user, flaggable) + respond_with flaggable, template: "#{controller_name}/_refresh_flag_actions" end private - def flagable + def flaggable instance_variable_get("@#{controller_name.singularize}") end