forked from eatvio/eatvio_app
fix(chat): model fields
This commit is contained in:
@@ -6,7 +6,7 @@ part 'chat_room_settings_model.g.dart';
|
||||
@freezed
|
||||
abstract class ChatRoomSettingsModel with _$ChatRoomSettingsModel {
|
||||
const factory ChatRoomSettingsModel({
|
||||
required String name,
|
||||
@JsonKey(name: 'room_name') required String name,
|
||||
required String state,
|
||||
}) = _ChatRoomSettingsModel;
|
||||
|
||||
|
||||
@@ -223,6 +223,7 @@ class ChatRoomCubit extends Cubit<ChatRoomState> {
|
||||
files: compressedFiles,
|
||||
slug: userSlug,
|
||||
);
|
||||
sl<ChatsCubit>().getChatRooms();
|
||||
return true;
|
||||
} catch (e, st) {
|
||||
log(e.toString(), stackTrace: st);
|
||||
|
||||
@@ -63,7 +63,8 @@ class ChatRepository {
|
||||
Future<ChatRoomModel> getChatRoom(String uuid) async {
|
||||
try {
|
||||
return (await chatService.getChatRoom(uuid: uuid));
|
||||
} catch (e) {
|
||||
} catch (e, st) {
|
||||
log(e.toString(), stackTrace: st);
|
||||
rethrow;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user