Skip to content

Commit

Permalink
Might have fixed it, will test tonight.
Browse files Browse the repository at this point in the history
  • Loading branch information
cdb84 committed Jan 6, 2021
1 parent 66521e0 commit d4c00cb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<groupId>client</groupId>
<artifactId>client</artifactId>
<packaging>jar</packaging>
<version>1.3-Stable</version>
<version>1.4-Beta</version>
<dependencyManagement>
<dependencies>
<dependency>
Expand Down
17 changes: 8 additions & 9 deletions client/src/main/java/client/AWSComboBoxListener.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package client;

import java.io.IOException;
import java.util.ArrayList;
import java.util.List;
import java.util.stream.Collectors;
Expand Down Expand Up @@ -153,23 +154,21 @@ private void exec(String selectedValue) {
return;
}
String subtitlePresign = handler.generatePresignedUrlFromKey(subtitlePath).toString();
if (!subtitlePath.equals("")){
if (!subtitlePath.equals("")) {
downloadFile(subtitlePresign, fileName);
if (exec.contains("vlc")){
createProcessBuilder(exec, presign, "--sub-file="+fileName);
if (exec.contains("vlc")) {
createProcessBuilder(exec, presign, "--sub-file=" + fileName);
}
}
else{
} else {
createProcessBuilder(exec, presign);
}
}
}

private void createProcessBuilder(String...args){
ProcessBuilder pb = new ProcessBuilder(args);
private void createProcessBuilder(String... args) {
try {
pb.start();
} catch (Exception e) {
Runtime.getRuntime().exec(args);
} catch (IOException e) {
e.printStackTrace();
}
}
Expand Down

0 comments on commit d4c00cb

Please sign in to comment.