Skip to content

Commit

Permalink
add limit to query
Browse files Browse the repository at this point in the history
  • Loading branch information
RuthNjeri committed Dec 23, 2020
1 parent 65c9d77 commit 42d89aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/controllers/home_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def dashboard
def dashboard_v2
# The new dashboard displays the blog and topics list
if current_user
@blog = Tag.find_nodes_by_type('blog', 'note', 1).first
@blog = Tag.find_nodes_by_type('blog', 'note', 1).limit(1).first
@tags = current_user.subscriptions(:tag).includes(:tag)
render template: 'dashboard/dashboard_v2'
else
Expand Down

0 comments on commit 42d89aa

Please sign in to comment.