SECURITY: Do not show latest/top topics on 404 for login_required sites
This commit is contained in:
parent
9e475860e0
commit
37300d6777
|
@ -2,28 +2,30 @@
|
||||||
|
|
||||||
<h1 class="page-not-found"><%= t 'page_not_found.title' %></h1>
|
<h1 class="page-not-found"><%= t 'page_not_found.title' %></h1>
|
||||||
|
|
||||||
<div class="row page-not-found-topics">
|
<% unless SiteSetting.login_required? && current_user.nil? %>
|
||||||
<div class="span8 popular-topics">
|
<div class="row page-not-found-topics">
|
||||||
<h2 class="popular-topics-title"><%= t 'page_not_found.popular_topics' %></h2>
|
<div class="span8 popular-topics">
|
||||||
<% @top_viewed.each do |t| %>
|
<h2 class="popular-topics-title"><%= t 'page_not_found.popular_topics' %></h2>
|
||||||
<div class='not-found-topic'>
|
<% @top_viewed.each do |t| %>
|
||||||
<%= link_to t.title, t.relative_url %><%= category_badge(t.category) %>
|
<div class='not-found-topic'>
|
||||||
</div>
|
<%= link_to t.title, t.relative_url %><%= category_badge(t.category) %>
|
||||||
<% end %>
|
</div>
|
||||||
<br/>
|
<% end %>
|
||||||
<a href="<%= path "/top" %>" class="btn"><%= t 'page_not_found.see_more' %>…</a>
|
<br/>
|
||||||
|
<a href="<%= path "/top" %>" class="btn"><%= t 'page_not_found.see_more' %>…</a>
|
||||||
|
</div>
|
||||||
|
<div class="span8 recent-topics">
|
||||||
|
<h2 class="recent-topics-title"><%= t 'page_not_found.recent_topics' %></h2>
|
||||||
|
<% @recent.each do |t| %>
|
||||||
|
<div class='not-found-topic'>
|
||||||
|
<%= link_to t.title, t.relative_url %><%= category_badge(t.category) %>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
<br/>
|
||||||
|
<a href="<%= path "/latest" %>" class="btn"><%= t 'page_not_found.see_more' %>…</a>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="span8 recent-topics">
|
<% end %>
|
||||||
<h2 class="recent-topics-title"><%= t 'page_not_found.recent_topics' %></h2>
|
|
||||||
<% @recent.each do |t| %>
|
|
||||||
<div class='not-found-topic'>
|
|
||||||
<%= link_to t.title, t.relative_url %><%= category_badge(t.category) %>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
<br/>
|
|
||||||
<a href="<%= path "/latest" %>" class="btn"><%= t 'page_not_found.see_more' %>…</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<%- unless @hide_google %>
|
<%- unless @hide_google %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
Loading…
Reference in New Issue