forked from eatvio/eatvio_app
Impoved autocomplete and partial encoding error fix
This commit is contained in:
@@ -170,7 +170,6 @@ class DiaryEditBloc extends Bloc<DiaryEditEvent, DiaryEditState> {
|
||||
final credentials = {
|
||||
'satiety': selectedSatiety,
|
||||
};
|
||||
print(json.encode(credentials));
|
||||
var response = await http.post(Uri.parse(url),
|
||||
headers: {
|
||||
'Authorization': 'Bearer $token',
|
||||
@@ -465,8 +464,9 @@ class DiaryEditBloc extends Bloc<DiaryEditEvent, DiaryEditState> {
|
||||
AddComment event, Emitter<DiaryEditState> emit) async {
|
||||
if (state is DiaryEditLoadedState) {
|
||||
var currentState = state as DiaryEditLoadedState;
|
||||
var updatedState =
|
||||
currentState.copyWith(commentController: event.comment);
|
||||
var updatedState = currentState.copyWith(
|
||||
commentController: TextEditingController(text: event.comment),
|
||||
);
|
||||
|
||||
// Отправляем данные по HTTP маршруту и ждем ответ
|
||||
var response = await sendCommentData(
|
||||
|
||||
Reference in New Issue
Block a user