adding code to post#index