Push conditionals inside branch expressions

This commit is contained in:
TacoTheDank 2020-10-31 15:57:26 -04:00
parent 710a840de6
commit 166cdd50f4
7 changed files with 26 additions and 26 deletions

View file

@ -646,7 +646,7 @@ public class DownloadDialog extends DialogFragment
mainStorage = mainStorageVideo; // subtitle & video files go together
format = subtitleStreamsAdapter.getItem(selectedSubtitleIndex).getFormat();
mime = format.mimeType;
filename += format == MediaFormat.TTML ? MediaFormat.SRT.suffix : format.suffix;
filename += (format == MediaFormat.TTML ? MediaFormat.SRT : format).suffix;
break;
default:
throw new RuntimeException("No stream selected");