You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I don't know if it's related to dryice or more to reflectable. But how can I inject class from another package?
Here is the code:
import 'package:dryice/dryice.dart';
import 'package:flutter_facebook_login/flutter_facebook_login.dart';
@inject
class FacebookService {
FacebookLogin facebookLogin;
@inject
FacebookService(this.facebookLogin);
Future<String> login() async {
FacebookLoginResult result = await facebookLogin.logInWithReadPermissions(['email']);
switch (result.status) {
case FacebookLoginStatus.loggedIn:
return Future.value(result.accessToken.token);
case FacebookLoginStatus.error:
return Future.error(new Exception(result.errorMessage));
case FacebookLoginStatus.cancelledByUser:
return Future.error(new Exception("Cancelled by user"));
}
// doesn't go here
return null;
}
And when i'm starting an app I get an exception:
E/flutter (24038): [ERROR:flutter/shell/common/shell.cc(181)] Dart Error: Unhandled exception:
E/flutter (24038): Reflecting on type 'FacebookLogin' without capability
The text was updated successfully, but these errors were encountered:
Hello, I don't know if it's related to dryice or more to reflectable. But how can I inject class from another package?
Here is the code:
And when i'm starting an app I get an exception:
The text was updated successfully, but these errors were encountered: