Skip to content

Commit

Permalink
Revert "don't send filename to server"
Browse files Browse the repository at this point in the history
This reverts commit 2728673.
Unfortunately, linx-server's file type detection does not always work,
so it's better to send a filename.
  • Loading branch information
mutantmonkey committed Nov 26, 2015
1 parent e33b607 commit 7f0faf9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion linx.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func linx(config *Config, filepath string, ttl int, deleteKey string) {
}
reader := progress.NewProgressReader(filename, bufio.NewReader(f), stat.Size())

req, err := http.NewRequest("PUT", config.Server+"upload", reader)
req, err := http.NewRequest("PUT", config.Server+"upload/"+filename, reader)
if err != nil {
log.Fatalf("Failed to create request: %v\n", err)
}
Expand Down

0 comments on commit 7f0faf9

Please sign in to comment.