Home how to call action from model to controller in ruby on rails
 I am trying to call 'checking' action from post model. class Post < ApplicationRecord after_commit :testing def testing @id = "#{self.id}" puts @id checking # call action to controller end end  posts_controller.rb def checking puts "not Working" end  I am trying to achieve the above, whereas it is not getting called.