Skip to content

Commit 07cd9e5

Browse files
committed
Allow configure() on an idle SDK instance (#63)
The assert was inverted: it rejected the empty (idle) status its message says is required, so any debug app calling configure() on a fresh instance crashed at startup.
1 parent 4205092 commit 07cd9e5

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎lib/src/codelessly.dart‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,7 @@ class Codelessly {
332332
initErrorLogger();
333333

334334
assert(
335-
status is! CEmpty,
335+
status is CEmpty || status is CConfigured,
336336
'The SDK cannot be configured if it is not idle. '
337337
'Consider calling [Codelessly.dispose] before reconfiguring.',
338338
);

0 commit comments

Comments
 (0)