hello i m trying to learn the same course and project and i m getting diffrent errors..@HayesGordon
Error: The getter 'accessToken' isn't defined for the class 'Future'.
../…/client/client.dart:290
- 'Future' is from 'dart:async'.
- 'ConnectGuestUserResponse' is from 'package:stream_chat/src/core/api/responses.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/api/responses.dart').
package:stream_chat/…/api/responses.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'accessToken'.
final guestUserToken = Token.fromRawValue(guestUser.accessToken);
^^^^^^^^^^^
: Error: The getter 'user' isn't defined for the class 'Future'.
../…/client/client.dart:292
-
'Future' is from 'dart:async'.
-
'ConnectGuestUserResponse' is from 'package:stream_chat/src/core/api/responses.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/api/responses.dart').
package:stream_chat/…/api/responses.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'user'.
guestUser.user,
: Error: A value of type 'Future' can't be assigned to a variable of type 'OwnUser?'.
../…/client/client.dart:330
-
'Future' is from 'dart:async'.
-
'OwnUser' is from 'package:stream_chat/src/core/models/own_user.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/models/own_user.dart').
package:stream_chat/…/models/own_user.dart:1
return state.currentUser = connectedUser;
: Error: The getter 'me' isn't defined for the class 'Future<Event?>'.
../…/client/client.dart:334
-
'Future' is from 'dart:async'.
-
'Event' is from 'package:stream_chat/src/core/models/event.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/models/event.dart').
package:stream_chat/…/models/event.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'me'.
if (event != null) return ownUser.merge(event.me);
: Error: A non-null value must be returned since the return type 'OwnUser' doesn't allow null.
../…/client/client.dart:342
-
'OwnUser' is from 'package:stream_chat/src/core/models/own_user.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/models/own_user.dart').
package:stream_chat/…/models/own_user.dart:1
Future openConnection() async {
^
2
FAILURE: Build failed with an exception.
Process 'command 'C:\Users\admin\Documents\flutter\bin\flutter.bat'' finished with non-zero exit value 1
BUILD FAILED in 1m 0s
Exception: Gradle task assembleDebug failed with exit code 1
hello i m trying to learn the same course and project and i m getting diffrent errors..@HayesGordon
Error: The getter 'accessToken' isn't defined for the class 'Future'.
../…/client/client.dart:290
package:stream_chat/…/api/responses.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'accessToken'.
final guestUserToken = Token.fromRawValue(guestUser.accessToken);
^^^^^^^^^^^
: Error: The getter 'user' isn't defined for the class 'Future'.
../…/client/client.dart:292
'Future' is from 'dart:async'.
'ConnectGuestUserResponse' is from 'package:stream_chat/src/core/api/responses.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/api/responses.dart').
package:stream_chat/…/api/responses.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'user'.
guestUser.user,
: Error: A value of type 'Future' can't be assigned to a variable of type 'OwnUser?'.
../…/client/client.dart:330
'Future' is from 'dart:async'.
'OwnUser' is from 'package:stream_chat/src/core/models/own_user.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/models/own_user.dart').
package:stream_chat/…/models/own_user.dart:1
return state.currentUser = connectedUser;
: Error: The getter 'me' isn't defined for the class 'Future<Event?>'.
../…/client/client.dart:334
'Future' is from 'dart:async'.
'Event' is from 'package:stream_chat/src/core/models/event.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/models/event.dart').
package:stream_chat/…/models/event.dart:1
Try correcting the name to the name of an existing getter, or defining a getter or field named 'me'.
if (event != null) return ownUser.merge(event.me);
: Error: A non-null value must be returned since the return type 'OwnUser' doesn't allow null.
../…/client/client.dart:342
'OwnUser' is from 'package:stream_chat/src/core/models/own_user.dart' ('../../../Documents/flutter/.pub-cache/hosted/pub.dartlang.org/stream_chat-3.3.1/lib/src/core/models/own_user.dart').
package:stream_chat/…/models/own_user.dart:1
Future openConnection() async {
^
2
FAILURE: Build failed with an exception.
Where:
Script 'C:\Users\admin\Documents\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1070
What went wrong:
Execution failed for task ':app:compileFlutterBuildDebug'.
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
BUILD FAILED in 1m 0s
Exception: Gradle task assembleDebug failed with exit code 1