Permissions Update

Fixes issue with documents being searchable even if the user doesn't
have permission to view the doc.