Page MenuHomestyx hydra

PhabricatorProjectsAllPolicyRule.php
No OneTemporary

PhabricatorProjectsAllPolicyRule.php

<?php
final class PhabricatorProjectsAllPolicyRule
extends PhabricatorProjectsBasePolicyRule {
public function getRuleDescription() {
return pht('members of all projects');
}
public function applyRule(
PhabricatorUser $viewer,
$value,
PhabricatorPolicyInterface $object) {
$memberships = $this->getMemberships($viewer->getPHID());
foreach ($value as $project_phid) {
if (empty($memberships[$project_phid])) {
return false;
}
}
return true;
}
public function getRuleOrder() {
return 205;
}
}

File Metadata

Mime Type
text/x-php
Expires
Mon, Dec 1, 6:08 PM (1 d, 12 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
429179
Default Alt Text
PhabricatorProjectsAllPolicyRule.php (568 B)

Event Timeline