Remove all "FileHasObject" edge reads and writes
[phabricator.git] / src / applications / auth / xaction / PhabricatorAuthPasswordRevokeTransaction.php
blobe5f9489f6efbb16ef5a02117f3373504a0c74ddf
1 <?php
3 final class PhabricatorAuthPasswordRevokeTransaction
4 extends PhabricatorAuthPasswordTransactionType {
6 const TRANSACTIONTYPE = 'password.revoke';
8 public function generateOldValue($object) {
9 return (bool)$object->getIsRevoked();
12 public function generateNewValue($object, $value) {
13 return (bool)$value;
16 public function applyInternalEffects($object, $value) {
17 $object->setIsRevoked((int)$value);
20 public function getTitle() {
21 if ($this->getNewValue()) {
22 return pht(
23 '%s revoked this password.',
24 $this->renderAuthor());
25 } else {
26 return pht(
27 '%s removed this password from the revocation list.',
28 $this->renderAuthor());