make PonderQuestionQuery policy aware

Summary: wanted to play with some policy stuff as its been a bit. Turns out you can't edit questions so this is very silly "so long as you are a user you can view it" policy. also sorry if you have a diff or twelve out for this in your sandbox(es).

Test Plan: loaded up ponder and clicked about

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, Korvin

Maniphest Tasks: T2113

Differential Revision: https://secure.phabricator.com/D4163
This commit is contained in:
Bob Trahan
2012-12-11 18:03:16 -08:00
parent 4041a7e0f6
commit a7f4103f51
5 changed files with 35 additions and 5 deletions

View File

@@ -34,7 +34,8 @@ final class PonderFeedController extends PonderController {
$pager->setOffset($request->getStr('offset'));
$pager->setURI($request->getRequestURI(), 'offset');
$query = new PonderQuestionQuery();
$query = id(new PonderQuestionQuery())
->setViewer($user);
if ($this->page == 'feed') {
$query