Fairly new to RoR and wondering how I might move this one line of code out of my view and into my controller. I am also using devise and a current user is logged in. Thanks in advance
profile.html.erb
<%= @profile.calorie / 4 %>
Ive set up a method called calculate within my profiles_controller.rb like so
helper_method :calculate
def calculate
.....
end