diff --git a/b0esche_cloud/lib/pages/file_explorer.dart b/b0esche_cloud/lib/pages/file_explorer.dart index b0181c8..3e54b22 100644 --- a/b0esche_cloud/lib/pages/file_explorer.dart +++ b/b0esche_cloud/lib/pages/file_explorer.dart @@ -318,14 +318,14 @@ class _FileExplorerState extends State { try { final fileService = getIt(); - + // Get token from SessionBloc for authentication final sessionState = context.read().state; String? token; if (sessionState is SessionActive) { token = sessionState.token; } - + if (token == null) { throw Exception('Not authenticated'); } @@ -336,7 +336,8 @@ class _FileExplorerState extends State { ); // Build full URL with token for authentication (anchor elements can't send headers) - final fullUrl = '${fileService.baseUrl}$downloadUrl&token=${Uri.encodeComponent(token)}'; + final fullUrl = + '${fileService.baseUrl}$downloadUrl&token=${Uri.encodeComponent(token)}'; // Trigger download via anchor element final anchor = web.HTMLAnchorElement() @@ -351,7 +352,11 @@ class _FileExplorerState extends State { SnackBar( content: Row( children: [ - const Icon(Icons.download_done, color: AppTheme.accentColor, size: 20), + const Icon( + Icons.download_done, + color: AppTheme.accentColor, + size: 20, + ), const SizedBox(width: 12), Expanded( child: Text(