diff --git a/lib/src/widgets/reactive_text_field.dart b/lib/src/widgets/reactive_text_field.dart index 08f4989..40cda1b 100644 --- a/lib/src/widgets/reactive_text_field.dart +++ b/lib/src/widgets/reactive_text_field.dart @@ -295,7 +295,8 @@ class _ReactiveTextFieldState @override void dispose() { - if (widget.textController == null) { + final currentWidget = widget as ReactiveTextField; + if (currentWidget._textController == null) { _textController.dispose(); } super.dispose();