Skip to content
This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions packages/firebase_crashlytics/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.1.0+2

* [iOS] Fixes crash when trying to report a crash without any context

## 0.1.0+1

* Added additional exception information from the Flutter framework to the reports.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,16 @@ - (void)handleMethodCall:(FlutterMethodCall *)call result:(FlutterResult)result
for (NSDictionary *errorElement in errorElements) {
[frames addObject:[self generateFrame:errorElement]];
}
[[Crashlytics sharedInstance]
recordCustomExceptionName:call.arguments[@"exception"]
reason:[NSString
stringWithFormat:@"thrown %s", call.arguments[@"context"]]
frameArray:frames];

NSString *context = call.arguments[@"context"];
NSString *reason;
if (context != nil) {
reason = [NSString stringWithFormat:@"thrown %@", context];
}

[[Crashlytics sharedInstance] recordCustomExceptionName:call.arguments[@"exception"]
reason:reason
frameArray:frames];
result(@"Error reported to Crashlytics.");
} else if ([@"Crashlytics#isDebuggable" isEqualToString:call.method]) {
result([NSNumber numberWithBool:[Crashlytics sharedInstance].debugMode]);
Expand Down
2 changes: 1 addition & 1 deletion packages/firebase_crashlytics/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: firebase_crashlytics
description:
Flutter plugin for Firebase Crashlytics. It reports uncaught errors to the
Firebase console.
version: 0.1.0+1
version: 0.1.0+2
author: Flutter Team <[email protected]>
homepage: https://github.com/flutter/plugins/tree/master/packages/firebase_crashlytics

Expand Down