Changed :topic_id to :id in topics_controller.rb