public function renderConfigPropertyTransactionTitle(PhabricatorAuthProviderConfigTransaction $xaction)
 {
     $author_phid = $xaction->getAuthorPHID();
     $old = $xaction->getOldValue();
     $new = $xaction->getNewValue();
     $key = $xaction->getMetadataValue(PhabricatorAuthProviderConfigTransaction::PROPERTY_KEY);
     switch ($key) {
         case self::PROPERTY_APP_ID:
             if (strlen($old)) {
                 return pht('%s updated the OAuth application ID for this provider from ' . '"%s" to "%s".', $xaction->renderHandleLink($author_phid), $old, $new);
             } else {
                 return pht('%s set the OAuth application ID for this provider to ' . '"%s".', $xaction->renderHandleLink($author_phid), $new);
             }
         case self::PROPERTY_APP_SECRET:
             if (strlen($old)) {
                 return pht('%s updated the OAuth application secret for this provider.', $xaction->renderHandleLink($author_phid));
             } else {
                 return pht('%s set the OAuth application secret for this provider.', $xaction->renderHandleLink($author_phid));
             }
         case self::PROPERTY_NOTE:
             if (strlen($old)) {
                 return pht('%s updated the OAuth application notes for this provider.', $xaction->renderHandleLink($author_phid));
             } else {
                 return pht('%s set the OAuth application notes for this provider.', $xaction->renderHandleLink($author_phid));
             }
     }
     return parent::renderConfigPropertyTransactionTitle($xaction);
 }
 public function renderConfigPropertyTransactionTitle(PhabricatorAuthProviderConfigTransaction $xaction)
 {
     $author_phid = $xaction->getAuthorPHID();
     $old = $xaction->getOldValue();
     $new = $xaction->getNewValue();
     $key = $xaction->getMetadataValue(PhabricatorAuthProviderConfigTransaction::PROPERTY_KEY);
     switch ($key) {
         case self::KEY_REQUIRE_SECURE:
             if ($new) {
                 return pht('%s turned "Require Secure Browsing" on.', $xaction->renderHandleLink($author_phid));
             } else {
                 return pht('%s turned "Require Secure Browsing" off.', $xaction->renderHandleLink($author_phid));
             }
     }
     return parent::renderConfigPropertyTransactionTitle($xaction);
 }
 public function renderConfigPropertyTransactionTitle(PhabricatorAuthProviderConfigTransaction $xaction)
 {
     $author_phid = $xaction->getAuthorPHID();
     $old = $xaction->getOldValue();
     $new = $xaction->getNewValue();
     $key = $xaction->getMetadataValue(PhabricatorAuthProviderConfigTransaction::PROPERTY_KEY);
     $labels = $this->getPropertyLabels();
     if (isset($labels[$key])) {
         $label = $labels[$key];
         $mask = false;
         switch ($key) {
             case self::KEY_ANONYMOUS_PASSWORD:
                 $mask = true;
                 break;
         }
         if ($mask) {
             return pht('%s updated the "%s" value.', $xaction->renderHandleLink($author_phid), $label);
         }
         if ($old === null || $old === '') {
             return pht('%s set the "%s" value to "%s".', $xaction->renderHandleLink($author_phid), $label, $new);
         } else {
             return pht('%s changed the "%s" value from "%s" to "%s".', $xaction->renderHandleLink($author_phid), $label, $old, $new);
         }
     }
     return parent::renderConfigPropertyTransactionTitle($xaction);
 }