fixed bugs

This commit is contained in:
dstark5
2023-10-24 04:05:29 -07:00
parent 9aeea38192
commit 3a95d79c4a
3 changed files with 4 additions and 8 deletions

View File

@ -82,9 +82,8 @@ Future<void> downloadFile(
throw err;
});
Future.delayed(const Duration(seconds: 5), () {
mirrorStatus(true);
});
mirrorStatus(true);
cancelDownlaod(cancelToken);
} catch (e) {
onDownlaodFailed();

View File

@ -53,9 +53,7 @@ class BookInfoPage extends ConsumerWidget {
var errJson = jsonDecode(err.toString());
if (SchedulerBinding.instance.schedulerPhase ==
SchedulerPhase.persistentCallbacks) {
SchedulerBinding.instance.addPostFrameCallback((_) async {
await Future.delayed(const Duration(seconds: 2));
// ignore: use_build_context_synchronously
SchedulerBinding.instance.addPostFrameCallback((_) {
Navigator.push(context,
MaterialPageRoute(builder: (BuildContext context) {
return Webview(url: errJson["url"]);

View File

@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 1.0.2+1
version: 1.0.3+1
environment:
sdk: '>=3.0.5 <4.0.0'
@ -47,7 +47,6 @@ dependencies:
path_provider: ^2.0.15
permission_handler: ^10.4.3
open_file: ^3.3.2
# flutter_inappwebview: ^5.8.0
http: ^1.1.0
webview_flutter: ^4.4.1
webview_cookie_manager: ^2.0.6