modified app/controller/pins_controller.rb