Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: php 8.2 fixes #6326

Merged
merged 1 commit into from
Apr 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion interface/main/calendar/includes/pnAPI.php
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ function pnVarPrepForDisplay()

foreach (func_get_args() as $ourvar) {
// Prepare var
$ourvar = htmlspecialchars($ourvar);
$ourvar = htmlspecialchars($ourvar ?? '');

$ourvar = preg_replace_callback(
$search,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
*/
function start_X12_Claimrev_send_files()
{
$autoSend = $GLOBALS['oe_claimrev_config_auto_send_claim_files'];
$autoSend = $GLOBALS['oe_claimrev_config_auto_send_claim_files'] ?? null;

if ($autoSend) {
ClaimUpload::sendWaitingFiles();
Expand All @@ -35,7 +35,7 @@ function start_X12_Claimrev_send_files()
function start_X12_Claimrev_get_reports()
{

$autoSend = $GLOBALS['oe_claimrev_config_auto_send_claim_files'];
$autoSend = $GLOBALS['oe_claimrev_config_auto_send_claim_files'] ?? null;

if ($autoSend) {
ReportDownload::getWaitingFiles();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

function start_send_eligibility()
{
$autoSend = $GLOBALS['oe_claimrev_send_eligibility'];
$autoSend = $GLOBALS['oe_claimrev_send_eligibility'] ?? null;
if ($autoSend) {
EligibilityTransfer::sendWaitingEligibility();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public function getAllAuthorizations()
private static function getAuthsFromModulePriorAuth(): array
{
$sql = "SELECT auth_num FROM module_prior_authorizations WHERE pid = ?";
$auths = sqlStatement($sql, [$_SESSION['pid']]);
$auths = sqlStatement($sql, [$_SESSION['pid'] ?? null]);
$auth_array = [];
while ($row = sqlFetchArray($auths)) {
$auth_array[] = $row['auth_num'];
Expand Down Expand Up @@ -105,7 +105,7 @@ private static function formPriorAuth(): array
private static function formMiscBilling()
{
$sql = "select prior_auth_number from form_misc_billing_options where pid = ?";
$auths = sqlStatement($sql, [$_SESSION['pid']]);
$auths = sqlStatement($sql, [$_SESSION['pid'] ?? null]);
$auths_array = [];
while ($row = sqlFetchArray($auths)) {
$auths_array[] = $row['prior_auth_number'];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ public function aclAction()
$data = $this->getAclTable()->getGroupAcl($module_id);
$saved_ACL = array();
foreach ($data as $row) {
if (!$saved_ACL[$row['section_id']]) {
if (empty($saved_ACL[$row['section_id']])) {
$saved_ACL[$row['section_id']] = array();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ $listener = $this->listenerObject;
<?php foreach($USER_GROUPS as $KEY => $VAL) : ?>
<?php
$selected = "";
if(is_array($ACL_DATA[$MODULE_DATA['module_name']['id']]) && in_array($KEY,$ACL_DATA[$MODULE_DATA['module_name']['id']])) $selected = "checked";
if(is_array($ACL_DATA[$MODULE_DATA['module_name']['id']] ?? null) && in_array($KEY,$ACL_DATA[$MODULE_DATA['module_name']['id']])) $selected = "checked";
?>
<td class="align_center"><input <?php echo $selected; ?> class="module_check" type="checkbox" name="<?php echo $this->escapeHtml($MODULE_DATA['module_name']['id']).'_'.$this->escapeHtml($KEY); ?>" id="<?php echo $this->escapeHtml($MODULE_DATA['module_name']['id']).'_'.$this->escapeHtml($KEY); ?>" ></td>
<?php endforeach ?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ class ModuleconfigForm extends Form
{
protected $zListener;

protected $application;

public function __construct(AdapterInterface $dbAdapter)
{
$this->application = new ApplicationTable();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ $(function () {
<a href="#" rel="previous" style="float:left;"><img src="<?php echo $this->basePath().'/images/prev.png' ?>" alt="" /></a>
<a href="#" rel="next" style="float:right;"><img src="<?php echo $this->basePath().'/images/next.png' ?>" alt="" /></a>
</div>
<ul class='virtualpage_<?php echo $this->escapeHtml($key);?> sortable_div droptrue <?php if(is_array($rowforms[1])) //echo "navigation";?>'>
<ul class='virtualpage_<?php echo $this->escapeHtml($key);?> sortable_div droptrue <?php if(is_array($rowforms[1] ?? null)) //echo "navigation";?>'>
<?php
$per_page = 13;
$count = 0;
Expand All @@ -136,7 +136,7 @@ $(function () {
?>
<li class='ui-state-default sortable_li <?php echo $this->escapeHtml($rowforms[1]);?>' id='<?php echo preg_replace('/\s/','_',$this->escapeHtml($rowforms[0]));?>'>
<?php echo $rowforms[0];
if(is_array($rowforms[2])){
if(is_array($rowforms[2] ?? null)){
?>
<ul class='droptrue' style='display: none;' id='sub_<?php echo preg_replace('/\s/','_',$this->escapeHtml($rowforms[0]));?>'>
<?php
Expand Down Expand Up @@ -209,7 +209,7 @@ $(function () {
<?php echo $this->listenerObject->z_xlt($row['ccda_sections_name']);?>
</li>
<?php
if($this->saved[$row['ccda_components_field']][$row['ccda_sections_field']]){
if($this->saved[$row['ccda_components_field']][$row['ccda_sections_field']] ?? null){
foreach($this->saved[$row['ccda_components_field']][$row['ccda_sections_field']] as $key_1 => $value_1){
if(!$this->listenerObject->z_xlt($this->saved[$row['ccda_components_field']][$row['ccda_sections_field']][$key_1]['name'])) continue;
?>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ public function configureAction()
'ListActiveUsers' => $this->getInstallerTable()->getActiveUsers(),
'ListActiveACL' => $this->getInstallerTable()->getActiveACL($modId),
'ListActiveHooks' => $this->getInstallerTable()->getActiveHooks($modId),
'helperObject' => $this->helperObject,
'helperObject' => $this->helperObject ?? null,
'configuration' => $configuration,
'hangers' => $this->getInstallerTable()->getHangers(),
'Hooks' => $hooksArr,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ public function getHookStatus($modId, $hookId, $hangerId)
$modArr = $row;
}

if ($modArr['mod_id'] <> "") {
if (!empty($modArr['mod_id'])) {
return "1";
} else {
return "0";
Expand Down Expand Up @@ -884,7 +884,7 @@ public function checkModuleHookExists($mod_id, $hookId)
$modArr = $row;
}

if ($modArr['obj_name'] <> "") {
if (!empty($modArr['obj_name'])) {
return "1";
} else {
return "0";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ if (count($TabSettings) > 0) {
?>
<tr>
<td width='15%'><?php echo $listener->z_xlt($element->getLabel()) ?></td>
<td><?php echo $this->formElement($element->setValue($configuration[$element->getAttribute('id')]['field_value'])); ?></td>
<td><?php echo $this->formElement($element->setValue($configuration[$element->getAttribute('id')]['field_value'] ?? null)); ?></td>
</tr>
<?php
$i++;
Expand Down