Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F13174074
D10012.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D10012.diff
View Options
Index: src/applications/maniphest/storage/ManiphestTask.php
===================================================================
--- src/applications/maniphest/storage/ManiphestTask.php
+++ src/applications/maniphest/storage/ManiphestTask.php
@@ -232,21 +232,29 @@
public function hasAutomaticCapability($capability, PhabricatorUser $user) {
+ $user_phid = $user->getPHID();
// The owner of a task can always view and edit it.
$owner_phid = $this->getOwnerPHID();
if ($owner_phid) {
- $user_phid = $user->getPHID();
if ($user_phid == $owner_phid) {
return true;
}
}
+ // The author of a task can always view and edit it.
+ $author_phid = $this->getAuthorPHID();
+ if ($author_phid) {
+ if ($user_phid == $author_phid) {
+ return true;
+ }
+ }
+
return false;
}
public function describeAutomaticCapability($capability) {
return pht(
- 'The owner of a task can always view and edit it.');
+ 'The author/owner of a task can always view and edit it.');
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, May 8, 9:58 PM (1 w, 5 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6271026
Default Alt Text
D10012.diff (1 KB)
Attached To
Mode
D10012: Allow authors to edit their tasks
Attached
Detach File
Event Timeline
Log In to Comment