@@ -56,8 +56,7 @@ public boolean submit(@NotNull IdeaLoggingEvent[] events,
56
56
@ NotNull Component parentComponent ,
57
57
@ NotNull Consumer <? super SubmittedReportInfo > consumer ) {
58
58
if (events .length == 0 ) {
59
- // Don't remove the cast until a later version of Android Studio.
60
- fail (((Consumer <SubmittedReportInfo >)consumer ));
59
+ fail (consumer );
61
60
return false ;
62
61
}
63
62
@@ -97,8 +96,7 @@ public boolean submit(@NotNull IdeaLoggingEvent[] events,
97
96
final DataContext dataContext = DataManager .getInstance ().getDataContext (parentComponent );
98
97
final Project project = PROJECT .getData (dataContext );
99
98
if (project == null ) {
100
- // Don't remove the cast until a later version of Android Studio.
101
- fail (((Consumer <SubmittedReportInfo >)consumer ));
99
+ fail (consumer );
102
100
return false ;
103
101
}
104
102
@@ -187,8 +185,7 @@ public boolean submit(@NotNull IdeaLoggingEvent[] events,
187
185
final VirtualFile file = scratchRoot .createScratchFile (project , "bug-report.md" , PlainTextLanguage .INSTANCE , text );
188
186
189
187
if (file == null ) {
190
- // Don't remove the cast until a later version of Android Studio.
191
- fail (((Consumer <SubmittedReportInfo >)consumer ));
188
+ fail (consumer );
192
189
return false ;
193
190
}
194
191
@@ -218,7 +215,7 @@ private static String getFlutterVersion(final FlutterSdk sdk) {
218
215
}
219
216
}
220
217
221
- private static void fail (@ NotNull Consumer <SubmittedReportInfo > consumer ) {
218
+ private static void fail (@ NotNull Consumer <? super SubmittedReportInfo > consumer ) {
222
219
consumer .consume (new SubmittedReportInfo (
223
220
null ,
224
221
null ,
0 commit comments