Differential D19901 Diff 47589 src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/transactions/editor/PhabricatorApplicationTransactionEditor.php
Show First 20 Lines • Show All 4,887 Lines • ▼ Show 20 Lines | foreach ($xactions as $xaction) { | ||||
break; | break; | ||||
} | } | ||||
} | } | ||||
if ($has_mfa) { | if ($has_mfa) { | ||||
return $xactions; | return $xactions; | ||||
} | } | ||||
// If the user is mentioning an MFA object on another object or creating | |||||
// a relationship like "parent" or "child" to this object, we allow the | |||||
// edit to move forward without requiring MFA. | |||||
if ($this->getIsInverseEdgeEditor()) { | |||||
return $xactions; | |||||
} | |||||
$template = $object->getApplicationTransactionTemplate(); | $template = $object->getApplicationTransactionTemplate(); | ||||
$mfa_xaction = id(clone $template) | $mfa_xaction = id(clone $template) | ||||
->setTransactionType($type_mfa) | ->setTransactionType($type_mfa) | ||||
->setNewValue(true); | ->setNewValue(true); | ||||
array_unshift($xactions, $mfa_xaction); | array_unshift($xactions, $mfa_xaction); | ||||
return $xactions; | return $xactions; | ||||
} | } | ||||
} | } |