* fix(mobile): clamp out of range datetimes so timeline queries cannot crash * replace the per column converters with a clamping custom type * heal each table in one statement, rename the clamp type, read dates as stored * one medium test for the clamp, drop the dart side bounds, private clamp type
14 lines
281 B
Dart
14 lines
281 B
Dart
import 'package:drift/drift.dart';
|
|
|
|
mixin DriftDefaultsMixin on Table {
|
|
@Deprecated('Use customType(clampedDateTime)')
|
|
@override
|
|
ColumnBuilder<DateTime> dateTime() => super.dateTime();
|
|
|
|
@override
|
|
bool get isStrict => true;
|
|
|
|
@override
|
|
bool get withoutRowId => true;
|
|
}
|