This commit is contained in:
Isaac Connor 2020-07-25 14:28:08 -04:00
parent 4c8f96b786
commit e90efa7a7e
1 changed files with 3 additions and 2 deletions

View File

@ -585,14 +585,14 @@ function getFormChanges($values, $newValues, $types=false, $columns=false) {
if ( !$types ) if ( !$types )
$types = array(); $types = array();
foreach( $newValues as $key=>$value ) { foreach ( $newValues as $key=>$value ) {
if ( $columns && !isset($columns[$key]) ) if ( $columns && !isset($columns[$key]) )
continue; continue;
if ( !isset($types[$key]) ) if ( !isset($types[$key]) )
$types[$key] = false; $types[$key] = false;
switch( $types[$key] ) { switch ( $types[$key] ) {
case 'set' : case 'set' :
if ( is_array($newValues[$key]) ) { if ( is_array($newValues[$key]) ) {
if ( (!isset($values[$key])) or ( join(',',$newValues[$key]) != $values[$key] ) ) { if ( (!isset($values[$key])) or ( join(',',$newValues[$key]) != $values[$key] ) ) {
@ -669,6 +669,7 @@ function getFormChanges($values, $newValues, $types=false, $columns=false) {
break; break;
} // end switch } // end switch
} // end foreach newvalues } // end foreach newvalues
foreach ( $values as $key=>$value ) { foreach ( $values as $key=>$value ) {
if ( !empty($columns[$key]) ) { if ( !empty($columns[$key]) ) {
if ( !empty($types[$key]) ) { if ( !empty($types[$key]) ) {