fixed tags#show when tag is not found

Bug introduced by commit 2b22e1dab
This commit is contained in:
Levente Bagi 2011-10-08 00:05:27 +01:00
parent d226c32f75
commit 43544a7bee

View file

@ -49,7 +49,7 @@ class TagsController < ApplicationController
params[:name].downcase!
@aspect = :tag
@tag = ActsAsTaggableOn::Tag.find_by_name(params[:name])
@tag_follow_count = @tag.followed_count
@tag_follow_count = @tag.try(:followed_count).to_i
if current_user
@posts = StatusMessage.owned_or_visible_by_user(current_user)