Skip to content

Commit

Permalink
Fix path variable in POST request
Browse files Browse the repository at this point in the history
  • Loading branch information
mobalt committed Apr 21, 2021
1 parent 946fc53 commit 9d4d6f5
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions src/views/Upload.vue
Original file line number Diff line number Diff line change
Expand Up @@ -453,11 +453,18 @@ export default {
}
}
let upload_path = this.imageSessions[i].directory;
//TODO: check if zip has been checked
if (true){
upload_path = await zipDirectory_old(upload_path);
this.imageSessions[i].directory = upload_path;
}
var options = [
host,
this.project,
this.imageSessions[i].sessionLabel,
await zipDirectory_old(this.imageSessions[i].directory),
upload_path,
this.inboxPath,
key,
localLog,
Expand Down Expand Up @@ -604,10 +611,7 @@ export default {
};
// var inboxPath = servers[i].inbox
console.log("imageSession.directory: " + imageSession.directory);
// var directories = imageSession.directory.split('/')
// var lastDirectory = directories[directories.length-1]
// var lastDirectory = path.basename(path.dirname(imageSession.directory))
var lastDirectory = imageSession.directory.split(path.sep).pop();
var lastDirectory = path.basename(imageSession.directory);
console.log("topDirectory: " + lastDirectory);
var options = settings.get("options");
Expand Down

0 comments on commit 9d4d6f5

Please sign in to comment.