mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-07-15 07:56:11 +08:00
Note sorting: 'created' can now be null
Earlier it was always something
This commit is contained in:
@ -178,10 +178,7 @@ class Note with ChangeNotifier implements Comparable<Note> {
|
||||
|
||||
var dt = modified ?? created;
|
||||
var otherDt = other.modified ?? other.created;
|
||||
if (dt == null && otherDt == null) {
|
||||
return filePath.compareTo(other.filePath);
|
||||
}
|
||||
if (dt.year == 0 || otherDt.year == 0) {
|
||||
if (dt == null || otherDt == null) {
|
||||
return filePath.compareTo(other.filePath);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user