Fix document title when viewing other users' favorites
This commit is contained in:
@@ -7,6 +7,7 @@ class FavoritesController < ApplicationController
|
|||||||
redirect_to(posts_path(:tags => params[:tags]))
|
redirect_to(posts_path(:tags => params[:tags]))
|
||||||
else
|
else
|
||||||
user_id = params[:user_id] || CurrentUser.user.id
|
user_id = params[:user_id] || CurrentUser.user.id
|
||||||
|
@user = User.find(user_id)
|
||||||
@favorite_set = PostSets::Favorite.new(user_id, params[:page], params)
|
@favorite_set = PostSets::Favorite.new(user_id, params[:page], params)
|
||||||
respond_with(@favorite_set.posts) do |format|
|
respond_with(@favorite_set.posts) do |format|
|
||||||
format.xml do
|
format.xml do
|
||||||
|
|||||||
@@ -25,7 +25,7 @@
|
|||||||
</section>
|
</section>
|
||||||
|
|
||||||
<% content_for(:page_title) do %>
|
<% content_for(:page_title) do %>
|
||||||
Favorites - <%= CurrentUser.name %> - <%= Danbooru.config.app_name %>
|
Favorites - <%= @user.pretty_name %> - <%= Danbooru.config.app_name %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render "posts/partials/common/secondary_links" %>
|
<%= render "posts/partials/common/secondary_links" %>
|
||||||
|
|||||||
Reference in New Issue
Block a user