View | Details | Raw Unified | Return to bug 21610
Collapse All | Expand All

(-)a/Koha/Object.pm (-2 / +3 lines)
Lines 141-147 sub store { Link Here
141
        }
141
        }
142
        elsif ( _date_or_datetime_column_type( $columns_info->{$col}->{data_type} ) ) {
142
        elsif ( _date_or_datetime_column_type( $columns_info->{$col}->{data_type} ) ) {
143
            # Set to null if an empty string (or == 0 but should not happen)
143
            # Set to null if an empty string (or == 0 but should not happen)
144
            $self->$col(undef) unless $self->$col;
144
            # Skip a default value for dates LIKE CURRENT_TIMESTAMP
145
            # In DBIx represented as: default_value => \'now()'
146
            $self->$col(undef) unless $self->$col || $columns_info->{$col}->{default_value};
145
        }
147
        }
146
    }
148
    }
147
149
148
- 

Return to bug 21610