Skip to content

Commit

Permalink
#22 - introducing initiate
Browse files Browse the repository at this point in the history
  • Loading branch information
turn-a-round committed May 23, 2020
1 parent 139699c commit c1e5dcb
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions src/sprightly/lib/core/initiate.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import 'package:sprightly/core/exceptions.dart';
import 'package:sprightly/utils/formatted_exception.dart';

Future<bool> initiate({
String environment,
Map<String, dynamic> configurations,
}) async {
try {
// add [PreConditionFailedException] to
exceptionDisplay[PreConditionFailedException] =
'Cannot go further. {message}';
return true;
} on Exception catch (e, st) {
throw FormattedException(
e,
stackTrace: st,
moduleName: 'sprightly.initiate',
);
}
}

0 comments on commit c1e5dcb

Please sign in to comment.