/**
  * @param int $id Project Id
  */
 public function initAction($id, $grantType = 'VIEW')
 {
     $redirectUrl = parent::initAction($id, $grantType);
     if ($redirectUrl) {
         return $redirectUrl;
     }
     $this->gitUndoCommands = $this->gitCommands->command('undo');
 }
 /**
  * @param int $id
  */
 public function initAction($id, $grantType = 'VIEW')
 {
     $em = $this->getDoctrine()->getManager();
     $redirectUrl = parent::initAction($id, $grantType);
     if ($redirectUrl) {
         return $redirectUrl;
     }
     $issueIntegrator = $em->getRepository('VersionControlGitControlBundle:ProjectIssueIntegrator')->findOneByProject($this->project);
     $this->issueManager = $this->get('version_control.issue_repository_manager');
     if ($issueIntegrator) {
         $this->issueManager->setIssueIntegrator($issueIntegrator);
     } else {
         $this->issueManager->setProject($this->project);
     }
     $this->issueMilestoneRepository = $this->issueManager->getIssueMilestoneRepository();
 }