Skip to content

Commit

Permalink
fixing #2 + Release 1.6b
Browse files Browse the repository at this point in the history
  • Loading branch information
ketankr9 committed Jan 6, 2020
1 parent 9602cde commit b1cff06
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 2 deletions.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ When users click right on a magnet link, there will be an option in the browser'
![setting](setting_page.png)

### Releases
**version: 1.6b**
* Now url links can also be added as magnet, solving [Issue#2](/~https://github.com/ketankr9/cloud-torrent-extension/issues/2)

**version: 1.5b**
* Click on a magnet and it will be sent to the cloud torrent. Used protocol_handlers for handling magnets.

Expand Down
Binary file removed cloud_torrent_magnet-1.5b-fx.xpi
Binary file not shown.
10 changes: 9 additions & 1 deletion magnet-extension/background.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,15 @@ browser.menus.create({
function MakeXhrRequest(magnetContent, serverip){

var xhr = new XMLHttpRequest();
xhr.open("POST", 'http://'+serverip+'/api/magnet', true);

var URL = 'http://'+serverip + '/api/';

if(magnetContent.slice(0,6) === 'magnet')
URL += 'magnet';
else
URL += 'url';

xhr.open("POST", URL, true);

//Include browser based Cookie header and Authorization header(if set)
xhr.withCredentials = true;
Expand Down
2 changes: 1 addition & 1 deletion magnet-extension/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"manifest_version": 2,
"name": "Cloud-Torrent-Magnet",
"description": "Send Magnet to Cloud-Torrent Server",
"version": "1.5b",
"version": "1.6b",
"applications": {
"gecko": {
"strict_min_version": "57.0"
Expand Down

0 comments on commit b1cff06

Please sign in to comment.