Skip to content
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
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,10 @@ class UploadCrashlyticsSymbols extends FlutterFireCommand {
}

if (projectId == null || appId == null) {
throw FirebaseJsonException();
final underlyingException =
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was also thinking about adding a separate message for a case when both projectId and appId is missing, but I'm not sure if it's needed - worst case user will first see projectId is missing and then appId is missing

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I think this works 😄

projectId == null ? 'projectId is missing.' : 'appId is missing.';

throw FirebaseJsonException(underlyingException: underlyingException);
}

return ConfigurationResults(
Expand Down
2 changes: 1 addition & 1 deletion packages/flutterfire_cli/lib/src/common/strings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ class FirebaseJsonException implements FlutterFireException {
final String? underlyingException;
@override
String toString() {
return 'FirebaseJsonException: Please run "flutterfire configure" to update the `firebase.json` at the root of your Flutter project with correct values. ${underlyingException != null ? '' : underlyingException}';
return 'FirebaseJsonException: Please run "flutterfire configure" to update the `firebase.json` at the root of your Flutter project with correct values. ${underlyingException ?? ''}';
}
}

Expand Down
Loading