Getting LateInitializationError randomly
Opened this issue · 1 comments
canewsin commented
I/flutter (13418): LateInitializationError: Field 'adIdManager' has not been initialized.
I/flutter (13418): #0 _EasySmartBannerAdState._isBannerIdAvailable (package:easy_ads_flutter/src/easy_smart_banner/easy_smart_banner.dart)
I/flutter (13418): #1 _EasySmartBannerAdState.build (package:easy_ads_flutter/src/easy_smart_banner/easy_smart_banner.dart:42)
I/flutter (13418): #2 StatefulElement.build (package:flutter/src/widgets/framework.dart:5409)
I/flutter (13418): #3 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:5297)
I/flutter (13418): #4 StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:5462)
I/flutter (13418): #5 Element.rebuild (package:flutter/src/widgets/framework.dart:5016)
I/flutter (13418): #6 ComponentElement._firstBuild (package:flutter/src/widgets/framework.dart:5279)
I/flutter (13418): #7 StatefulElement._firstBuild (package:flutter/src/widgets/framework.dart:5453)
I/flutter (13418): #8 ComponentElement.mount (package:flutter/src/widgets/framework.dart:5273)
I/flutter (13418): #12 StatefulElement.performRebuild (package:flutter/src/widgets/framework.dart:5462)
I/flutter (13418): #13 Element.rebuild (package:flutter/src/widgets/framework.dart:5016)
I/flutter (13418): #14 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2779)
I/flutter (13418): #15 WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:916)
I/flutter (13418): #16 RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:360)
I/flutter (13418): #17 SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1297)
I/flutter (13418): #18 SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1227)
I/flutter (13418): #19 SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:1085)
I/flutter (13418): #20 _invoke (dart:ui/hooks.dart:170)
I/flutter (13418): #21 PlatformDispatcher._drawFrame (dart:ui/platform_dispatcher.dart:401)
I/flutter (13418): #22 _drawFrame (dart:ui/hooks.dart:140)
uveshm003 commented
Check if you are not using 'adIdManager' in any function before initializing in such complex code it is very easy to make such small mistakes. you will solve this error if you just review you code and check everywhere you are using 'adIdManager'.