Page MenuHomePhabricator

D7758.diff

diff --git a/src/applications/phortune/storage/PhortuneAccount.php b/src/applications/phortune/storage/PhortuneAccount.php
--- a/src/applications/phortune/storage/PhortuneAccount.php
+++ b/src/applications/phortune/storage/PhortuneAccount.php
@@ -46,7 +46,12 @@
}
public function getPolicy($capability) {
- return PhabricatorPolicies::POLICY_NOONE;
+ if ($this->getPHID() === null) {
+ // Allow a user to create an account for themselves.
+ return PhabricatorPolicies::POLICY_USER;
+ } else {
+ return PhabricatorPolicies::POLICY_NOONE;
+ }
}
public function hasAutomaticCapability($capability, PhabricatorUser $viewer) {

File Metadata

Mime Type
text/x-diff
Storage Engine
amazon-s3
Storage Format
Raw Data
Storage Handle
phabricator/a6/kd/5vqlch62antrvk6j
Default Alt Text
D7758.diff (666 B)

Event Timeline