Skip to content

Commit db58afb

Browse files
authored
[LINST] Fixed default date field null error (#7559)
When creating a date element in the instrument builder without specifying start and end values, the module defaults the values to 1900 and 2100 which in turn cause a type error when rendering the instrument. This should fix that error without changing any functionality.
1 parent 1915070 commit db58afb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

php/libraries/NDB_BVL_Instrument_LINST.class.inc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -564,7 +564,7 @@ class NDB_BVL_Instrument_LINST extends \NDB_BVL_Instrument
564564
case 'date':
565565
if ($addElements) {
566566
if ($pieces[3] == 1900 && $pieces[4] == 2100) {
567-
$dateOptions = null;
567+
$dateOptions = [];
568568
} else {
569569
$dateOptions = array(
570570
'language' => 'en',

0 commit comments

Comments
 (0)