Added methods to allow the new task screen to update the blocs properties

This commit is contained in:
Mariano Uvalle 2019-03-31 23:42:27 -06:00
parent 2c42d3c4a2
commit 4db0ab4e53

View file

@ -6,4 +6,20 @@ import '../models/task_model.dart';
import '../resources/authService.dart';
import '../resources/firestore_provider.dart';
class NewTaskBloc {}
class NewTaskBloc {
final AuthService _auth = authService;
FirebaseUser currentUser;
String text;
TaskPriority priority;
String event;
NewTaskBloc() {
setCurrentUser();
}
Future<void> setCurrentUser() async {
final user = await _auth.currentUser;
currentUser = user;
}
}