Home > Software engineering >  Instance member 'data' can't be accessed using static access
Instance member 'data' can't be accessed using static access

Time:09-14

I/m facing this issue. Can anyone assist? Thanks

CodePudding user response:

You have a null safety. Just add '!' after data. Example snapshot!.data!.[i].name

CodePudding user response:

To complement KOrra's answer, In line 44, you have AsyncSnaphot.data.lenght. It should be snapshot.data.length

  • Related