Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15380927
D18763.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D18763.diff
View Options
diff --git a/src/applications/project/__tests__/PhabricatorProjectCoreTestCase.php b/src/applications/project/__tests__/PhabricatorProjectCoreTestCase.php
--- a/src/applications/project/__tests__/PhabricatorProjectCoreTestCase.php
+++ b/src/applications/project/__tests__/PhabricatorProjectCoreTestCase.php
@@ -146,8 +146,7 @@
$user = $this->createUser();
$user->save();
- $user2 = $this->createUser();
- $user2->save();
+ $user->setAllowInlineCacheGeneration(true);
$proj = $this->createProject($user);
@@ -1289,12 +1288,19 @@
$new_name = $proj->getName().' '.mt_rand();
- $xaction = new PhabricatorProjectTransaction();
- $xaction->setTransactionType(
- PhabricatorProjectNameTransaction::TRANSACTIONTYPE);
- $xaction->setNewValue($new_name);
+ $params = array(
+ 'objectIdentifier' => $proj->getID(),
+ 'transactions' => array(
+ array(
+ 'type' => 'name',
+ 'value' => $new_name,
+ ),
+ ),
+ );
- $this->applyTransactions($proj, $user, array($xaction));
+ id(new ConduitCall('project.edit', $params))
+ ->setUser($user)
+ ->execute();
return true;
}
diff --git a/src/applications/project/editor/PhabricatorProjectTransactionEditor.php b/src/applications/project/editor/PhabricatorProjectTransactionEditor.php
--- a/src/applications/project/editor/PhabricatorProjectTransactionEditor.php
+++ b/src/applications/project/editor/PhabricatorProjectTransactionEditor.php
@@ -120,16 +120,6 @@
PhabricatorApplicationTransaction $xaction) {
switch ($xaction->getTransactionType()) {
- case PhabricatorProjectNameTransaction::TRANSACTIONTYPE:
- case PhabricatorProjectStatusTransaction::TRANSACTIONTYPE:
- case PhabricatorProjectImageTransaction::TRANSACTIONTYPE:
- case PhabricatorProjectIconTransaction::TRANSACTIONTYPE:
- case PhabricatorProjectColorTransaction::TRANSACTIONTYPE:
- PhabricatorPolicyFilter::requireCapability(
- $this->requireActor(),
- $object,
- PhabricatorPolicyCapability::CAN_EDIT);
- return;
case PhabricatorProjectLockTransaction::TRANSACTIONTYPE:
PhabricatorPolicyFilter::requireCapability(
$this->requireActor(),
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sat, Mar 15, 5:02 AM (1 w, 2 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7683803
Default Alt Text
D18763.diff (2 KB)
Attached To
Mode
D18763: Remove some defunct old-style transaction policy checks
Attached
Detach File
Event Timeline
Log In to Comment