changed messages to toast
This commit is contained in:
@@ -7,6 +7,7 @@ import 'package:tm_app/core/routes/app_routes.dart';
|
||||
import 'package:tm_app/view_models/profile_view_model.dart';
|
||||
|
||||
import '../../../core/theme/colors.dart';
|
||||
import '../../../core/utils/app_toast.dart';
|
||||
import '../../../core/utils/size_config.dart';
|
||||
import '../../shared/tablet_navigation_widget.dart';
|
||||
import '../../shared/tender_app_bar.dart';
|
||||
@@ -32,12 +33,7 @@ class _TabletProfilePageState extends State<TabletProfilePage> {
|
||||
|
||||
void _profileListener() {
|
||||
if (viewModel.errorMessage != null) {
|
||||
ScaffoldMessenger.of(context).showSnackBar(
|
||||
SnackBar(
|
||||
content: Text(viewModel.errorMessage!),
|
||||
backgroundColor: AppColors.red,
|
||||
),
|
||||
);
|
||||
AppToast.error(context, viewModel.errorMessage!);
|
||||
}
|
||||
if (viewModel.loggedOut) {
|
||||
Router.neglect(context, () => LoginScreenRoute().go(context));
|
||||
|
||||
Reference in New Issue
Block a user