mirror of
https://github.com/RipMeApp/ripme.git
synced 2025-08-29 08:40:37 +02:00
Fix for IllegalArgumentException on pathing
This commit is contained in:
@@ -322,8 +322,13 @@ public class Utils {
|
||||
* @return saveAs in relation to the CWD
|
||||
*/
|
||||
public static String removeCWD(Path saveAs) {
|
||||
try {
|
||||
return saveAs.relativize(Paths.get(".").toAbsolutePath()).toString();
|
||||
}
|
||||
catch (IllegalArgumentException e) {
|
||||
return saveAs.toString();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Strips away URL parameters, which usually appear at the end of URLs. E.g. the
|
||||
|
Reference in New Issue
Block a user