projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Replace CRM_Utils_Array::value with ?? in variable assignments
[civicrm-core.git]
/
CRM
/
Financial
/
BAO
/
PaymentProcessor.php
diff --git
a/CRM/Financial/BAO/PaymentProcessor.php
b/CRM/Financial/BAO/PaymentProcessor.php
index b2508ec8653427b978c45ec31b27c1ec2f887b8f..21d26259ac2af9fc26f15315521e75e2e21fbf1a 100644
(file)
--- a/
CRM/Financial/BAO/PaymentProcessor.php
+++ b/
CRM/Financial/BAO/PaymentProcessor.php
@@
-262,8
+262,8
@@
class CRM_Financial_BAO_PaymentProcessor extends CRM_Financial_DAO_PaymentProces
* @return int
*/
public static function defaultComparison($processor1, $processor2) {
* @return int
*/
public static function defaultComparison($processor1, $processor2) {
- $p1 =
CRM_Utils_Array::value('is_default', $processor1)
;
- $p2 =
CRM_Utils_Array::value('is_default', $processor2)
;
+ $p1 =
$processor1['is_default'] ?? NULL
;
+ $p2 =
$processor2['is_default'] ?? NULL
;
if ($p1 == $p2) {
return 0;
}
if ($p1 == $p2) {
return 0;
}
@@
-335,7
+335,7
@@
class CRM_Financial_BAO_PaymentProcessor extends CRM_Financial_DAO_PaymentProces
}
}
$processors['values'][$processor['id']]['payment_processor_type'] = $processor['payment_processor_type'] = $processors['values'][$processor['id']]['api.payment_processor_type.getsingle']['name'];
}
}
$processors['values'][$processor['id']]['payment_processor_type'] = $processor['payment_processor_type'] = $processors['values'][$processor['id']]['api.payment_processor_type.getsingle']['name'];
- $processors['values'][$processor['id']]['object'] = Civi\Payment\System::singleton()->getByProcessor($processor);
+ $processors['values'][$processor['id']]['object'] = Civi\Payment\System::singleton()->getByProcessor($processor
s['values'][$processor['id']]
);
}
// Add the pay-later pseudo-processor.
}
// Add the pay-later pseudo-processor.
@@
-532,7
+532,7
@@
INNER JOIN civicrm_contribution con ON ( mp.contribution_id = con.id )
}
}
- $ppID = (isset($dao->ppID1) && $dao->ppID1) ? $dao->ppID1 : (
isset($dao->ppID2) ? $dao->ppID2 :
NULL);
+ $ppID = (isset($dao->ppID1) && $dao->ppID1) ? $dao->ppID1 : (
$dao->ppID2 ??
NULL);
$mode = (isset($dao->is_test) && $dao->is_test) ? 'test' : 'live';
if (!$ppID || $type == 'id') {
$result = $ppID;
$mode = (isset($dao->is_test) && $dao->is_test) ? 'test' : 'live';
if (!$ppID || $type == 'id') {
$result = $ppID;