Commit 907782b8 authored by 张宏's avatar 张宏

1111

parent b5abe691
......@@ -188,26 +188,6 @@ class _MyAppState extends State<MyApp> {
),
// BlocProvider<CounterBloc>(create: (_) => CounterBloc()),
],
child: MultiBlocListener(
listeners: [
// // AuthBloc 监听器 - 处理登录/Token 过期/登出
// BlocListener<AuthBloc, AuthState>(
// listener: (context, state) {
// if (state is AuthSuccess) {
// _appRouter.replaceAll([const DefaultLayoutRoute()]);
// }
// if (state is AuthTokenExpired) {
// _silentLogin();
// }
// if (state is AuthLoggedOut) {
// _silentLogin();
// }
// },
// ),
// 未来在这里添加其他 Bloc 的监听器:
// BlocListener<UserBloc, UserState>(listener: ...),
// BlocListener<SettingsBloc, SettingsState>(listener: ...),
],
child: Stack(
children: [
MaterialApp.router(
......@@ -224,7 +204,6 @@ class _MyAppState extends State<MyApp> {
if (_isInitializing) _buildSplash(),
],
),
),
);
},
);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment