Use pathname in torrent upload

This commit is contained in:
Luminarys 2017-10-22 21:16:30 -07:00
parent 98accb302a
commit b7b48916cd

View File

@ -53,7 +53,7 @@ class AddTorrent extends Component {
console.log(socket);
const a = document.createElement('a');
a.href = socket.uri;
const url = (a.protocol === "ws:" ? "http://" : "https://") + a.host;
const url = (a.protocol === "ws:" ? "http://" : "https://") + a.host + a.pathname;
try {
const resp = await fetch(url,
{