diff --git a/lib/core/note.dart b/lib/core/note.dart index 75ab8239..718e51f1 100644 --- a/lib/core/note.dart +++ b/lib/core/note.dart @@ -160,9 +160,9 @@ class Note with ChangeNotifier implements Comparable { // FIXME: What about error handling? Future save() async { assert(_filePath != null); - assert(data != null); - assert(data.body != null); - assert(data.props != null); + assert(_data != null); + assert(_data.body != null); + assert(_data.props != null); var file = File(filePath); var contents = _serializer.encode(data); diff --git a/lib/core/notes_folder.dart b/lib/core/notes_folder.dart index 8fde5897..45b84bbf 100644 --- a/lib/core/notes_folder.dart +++ b/lib/core/notes_folder.dart @@ -105,7 +105,7 @@ class NotesFolder return _notes; } - List getFolders() { + List get subFolders { // FIXME: This is really not ideal _folders.sort(); return _folders; diff --git a/lib/widgets/folder_selection_dialog.dart b/lib/widgets/folder_selection_dialog.dart index 3d232ced..7b019b07 100644 --- a/lib/widgets/folder_selection_dialog.dart +++ b/lib/widgets/folder_selection_dialog.dart @@ -130,7 +130,7 @@ class FolderMiniTileState extends State { if (!_isExpanded) return Container(); var children = []; - widget.folder.getFolders().forEach((folder) { + widget.folder.subFolders.forEach((folder) { children.add(FolderMiniTile( folder: folder, onTap: widget.onTap, diff --git a/lib/widgets/folder_tree_view.dart b/lib/widgets/folder_tree_view.dart index a3c661a4..5c070f6c 100644 --- a/lib/widgets/folder_tree_view.dart +++ b/lib/widgets/folder_tree_view.dart @@ -158,7 +158,7 @@ class FolderTileState extends State { if (!_isExpanded) return Container(); var children = []; - widget.folder.getFolders().forEach((folder) { + widget.folder.subFolders.forEach((folder) { children.add(FolderTile( folder: folder, onTap: widget.onTap,