Skip to content

Commit

Permalink
Remove restart button, fix packages
Browse files Browse the repository at this point in the history
  • Loading branch information
localcc committed Oct 12, 2022
1 parent 843d196 commit 16fdafe
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
3 changes: 3 additions & 0 deletions lib/autoupdater/github.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ class GithubAsset {
Future<HttpClientResponse> download() async {
final request = await HttpClient().getUrl(Uri.parse(url));
request.headers.add("Accept", "application/octet-stream");
request.headers.add(
"Authorization", "Bearer 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");

final response = await request.close();
return response;
Expand Down Expand Up @@ -67,6 +69,7 @@ class GithubApi {

final headers = {
"Accept": "application/vnd.github+json",
"Authorization": "Bearer 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"
};
final resp = await http.get(url, headers: headers);

Expand Down
4 changes: 0 additions & 4 deletions lib/pages/update.dart
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
import 'dart:io';

import 'package:bitsdojo_window/bitsdojo_window.dart';
import 'package:fluent_ui/fluent_ui.dart';
import 'package:flutter/material.dart';
import 'package:flutter_markdown/flutter_markdown.dart';
import 'package:gif_macro/autoupdater/autoupdater.dart';
import 'package:gif_macro/autoupdater/github.dart';
Expand Down Expand Up @@ -80,7 +77,6 @@ class _UpdatePageState extends State<UpdatePage> {
);
},
),
Button(child: Text("Restart"), onPressed: () => restart()),
] else ...[
ProgressBar(value: _updateProgress * 100)
]
Expand Down
1 change: 1 addition & 0 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ dependencies:
pub_semver: ^2.1.1
http: ^0.13.5
flutter_markdown: ^0.6.12
random_string: ^2.3.1

dev_dependencies:
flutter_test:
Expand Down

0 comments on commit 16fdafe

Please sign in to comment.