Skip to content

Commit

Permalink
fix(#17) : throw error when wrong child is entered
Browse files Browse the repository at this point in the history
  • Loading branch information
JordyHers committed Jun 21, 2023
1 parent d4f4ab8 commit e9b1c3d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lib/app/pages/set_child_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,15 @@ class _SetChildPageState extends State<SetChildPage> {
JHLogger.$.e('ERROR OCCURRED COULD NOT MOVE TO THE NEXT PAGE');
}
} catch (e) {
setState(() {
appState = AppState.complete;
});
await showAlertDialog(
context,
title: 'No Such file in Database',
content: 'ERROR OCCURRED COULD NOT MOVE TO THE NEXT PAGE',
defaultActionText: 'OK',
);
JHLogger.$.e(e.toString());
}
}
Expand All @@ -89,6 +98,7 @@ class _SetChildPageState extends State<SetChildPage> {
),
),
TextField(
textCapitalization: TextCapitalization.characters,
enabled: appState == AppState.loading ? false : true,
focusNode: _keyFocusNode,
controller: _key,
Expand Down

0 comments on commit e9b1c3d

Please sign in to comment.