Skip to content

Commit

Permalink
Merge pull request #135 from MXCzkEVM/big_upgrade
Browse files Browse the repository at this point in the history
Big upgrade
  • Loading branch information
reasje authored Dec 18, 2024
2 parents d6f2eac + 6c4d882 commit c609272
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 7 deletions.
22 changes: 18 additions & 4 deletions lib/core/src/firebase/moonchain_wallet_firebase.dart
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import 'dart:io';

import 'package:clipboard/clipboard.dart';
import 'package:firebase_crashlytics/firebase_crashlytics.dart';
import 'package:moonchain_wallet/common/common.dart';
import 'package:moonchain_wallet/core/src/moonchain_wallet_notification.dart';
import 'package:firebase_core/firebase_core.dart';
Expand Down Expand Up @@ -87,10 +88,23 @@ class MoonchainWalletFireBase {

static void incrementBuildTap() async {
buildTap++;
if (buildTap == 10) {
final token = await FirebaseMessaging.instance.getToken();
FlutterClipboard.copy(token ?? 'Unable to get token');
buildTap = 0;
if (buildTap % 2 == 0) {
forceFullCrash();
} else {
forceCrash();
}
// if (buildTap == 10) {
// final token = await FirebaseMessaging.instance.getToken();
// FlutterClipboard.copy(token ?? 'Unable to get token');
// buildTap = 0;
// }
}

static void forceCrash() {
throw Exception("Test crash to verify Firebase Crashlytics integration.");
}

static void forceFullCrash() {
FirebaseCrashlytics.instance.crash();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ class BlueberryRingUseCase extends ReactiveUseCase {
withKeywords: ['2301'],
);

await Future.delayed(const Duration(seconds: 4), () async {
await Future.delayed(const Duration(seconds: 6), () async {
final scanResults = _bluetoothUseCase.scanResults.value;
if (scanResults.isNotEmpty) {
// only one scan results
Expand Down
2 changes: 1 addition & 1 deletion packages/shared
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ publish_to: "none" # Remove this line if you wish to publish to pub.dev
# 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.4.4
version: 1.4.5


environment:
Expand Down

0 comments on commit c609272

Please sign in to comment.