Add before_action snippet