class TagsController < ApplicationController
  # GET /tags
  def index
    @tags = Tag.all
  end

  # GET /tags/:id
  def show
    @tag = Tag.find(params[:id])
    @ideas = @tag.ideas
  end
end

class TagsController < ApplicationController

  before_action :set_tag, only: [:show]

  # GET /tags
  def index
    @tags = Tag.all
  end

  # GET /tags/:id
  def show
    @ideas = @tag.ideas
  end
end

Use a 'before_action' in the Tags controller
Use a 'before_action' in the Tags controller

Before the 'show' action, set the Tag to be shown with a
'before_action.'
