aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Vijay A <avijayr@protonmail.com>2021-09-20 14:49:55 +0530
committerLibravatar Vijay Aravamudhan <vraravam@users.noreply.github.com>2021-09-20 15:05:04 +0530
commit0a3387f19918bc1012ad2ee3db7bc6771caa9624 (patch)
tree4ea305614538e8400bf8ecbec55e868394891609
parentfix: fix js error; styling (diff)
downloadferdium-recipes-0a3387f19918bc1012ad2ee3db7bc6771caa9624.tar.gz
ferdium-recipes-0a3387f19918bc1012ad2ee3db7bc6771caa9624.tar.zst
ferdium-recipes-0a3387f19918bc1012ad2ee3db7bc6771caa9624.zip
fix: Remove extra validation for serviceUrl for github since the url doesn't seem to be valid any more.
-rw-r--r--all.json2
-rw-r--r--recipes/github/index.js17
-rw-r--r--recipes/github/package.json4
3 files changed, 3 insertions, 20 deletions
diff --git a/all.json b/all.json
index e2efd7f..6b1cb56 100644
--- a/all.json
+++ b/all.json
@@ -490,7 +490,7 @@
490 "featured": false, 490 "featured": false,
491 "id": "github", 491 "id": "github",
492 "name": "GitHub", 492 "name": "GitHub",
493 "version": "2.2.1", 493 "version": "2.3.0",
494 "icons": { 494 "icons": {
495 "svg": "https://cdn.jsdelivr.net/gh/getferdi/recipes/recipes/github/icon.svg" 495 "svg": "https://cdn.jsdelivr.net/gh/getferdi/recipes/recipes/github/icon.svg"
496 } 496 }
diff --git a/recipes/github/index.js b/recipes/github/index.js
index dfcd7d1..a84e54a 100644
--- a/recipes/github/index.js
+++ b/recipes/github/index.js
@@ -1,19 +1,2 @@
1module.exports = Ferdi => class GitHub extends Ferdi { 1module.exports = Ferdi => class GitHub extends Ferdi {
2 async validateUrl(url) {
3 try {
4 const resp = await window.fetch(`${url}/api/v3`, {
5 method: 'GET',
6 headers: {
7 'Content-Type': 'application/json',
8 Accept: 'application/vnd.github.v3+json',
9 },
10 });
11 // doc: https://developer.github.com/enterprise/2.17/v3/#current-version
12 return resp.status.toString().startsWith('2');
13 } catch (err) {
14 console.error(err);
15 }
16
17 return false;
18 }
19}; 2};
diff --git a/recipes/github/package.json b/recipes/github/package.json
index 0f9bb51..5a35240 100644
--- a/recipes/github/package.json
+++ b/recipes/github/package.json
@@ -1,11 +1,11 @@
1{ 1{
2 "id": "github", 2 "id": "github",
3 "name": "GitHub", 3 "name": "GitHub",
4 "version": "2.2.1", 4 "version": "2.3.0",
5 "license": "MIT", 5 "license": "MIT",
6 "config": { 6 "config": {
7 "serviceURL": "https://github.com/notifications", 7 "serviceURL": "https://github.com/notifications",
8 "hasCustomUrl": true, 8 "hasHostedOption": true,
9 "hasIndirectMessages": true 9 "hasIndirectMessages": true
10 } 10 }
11} 11}