def set_paginator
      posts_scope = Post.published

      if @tag
        posts_scope = posts_scope.joins(:tags).where("#{Tag.table_name}.name = ?", @tag)
      end

      @paginator = Paginator.new(
        posts_scope,
        :page     => (params[:page] || 1),
        :per_page => Blogo.config.posts_per_page,
        :size     => Blogo.config.paginator_size)
    end
def set_paginator
      posts_scope = Post.published

      if @tag
        posts_scope = posts_scope.joins(:tags).where("#{Tag.table_name}.name = ?", @tag)
      end

      @paginator = Paginator.new(
        posts_scope,
        :page     => (params[:page] || 1),
        :per_page => Blogo.config.posts_per_page,
        :size     => Blogo.config.paginator_size)
    end
Build a paginator object and set to @paginator.

 @return [Blogo::Paginator]