fix n+1 problem for namespaces
Merge pull request #6062 from skv-headless/fix_n+1_user_page

fix n+1 problem for namespaces