Merge request tree filtering only seaches file name not path

Summary

Searching for a fragment from a directory doesnt' work in the merge request file tree, making it hard to find changes to docs (e.g. search doc)

Steps to reproduce

  1. Open https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/22560/diffs#5f83c9c52ccde899cf2c6bca71a57913e33520ad
  2. Filter by doc

Example Project

https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/22560

What is the current bug behavior?

Search doc Search user Search index
20181109_screenshot_20 20181109_screenshot_21 20181109_screenshot_22

What is the expected correct behavior?

The file doc/user/profile/index.md should be shown in all the searches above, not only for index

Relevant logs and/or screenshots

Above

Output of checks

This bug happens on GitLab.com