flags: fix flagger:<name> not returning self-flagged uploads

Fix the search `flagger:evazion user:evazion` not returning the user's own self-flagged uploads.

Followup to a6e0872ce.

Fixes #4690: user profile 'flags' count links to /post_flags with different search criteria
This commit is contained in:
evazion
2022-09-22 22:31:33 -05:00
parent dff27e3a3a
commit e5edd79180
5 changed files with 14 additions and 29 deletions

View File

@@ -220,7 +220,7 @@ class UsersControllerTest < ActionDispatch::IntegrationTest
get_auth profile_path, @user, as: :json
assert_response :success
assert_equal(@user.comment_count, response.parsed_body["comment_count"])
assert_equal(@user.comments.count, response.parsed_body["comment_count"])
end
should "redirect anonymous users to the sign in page" do