-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix [GreasyFork] 404 bug #9632
fix [GreasyFork] 404 bug #9632
Conversation
Can you explain the relationship between greasyfork and sleazyfork for someone who doesn't use either? It is clear they are closely related services, but my instinct is that it would make more sense to add sleazyfork as its own service, rather than treating it as a fallback for greasyfork. |
See https://greasyfork.org/en/forum/discussion/5456/adult-content for reasons. Basically, if a script works on an "adult" sites (even if it's one such site out of a thousand), it cannot be seen on GreasyFork without being logged in. Sleazyfork is another inlet to Greasyfork, where adult scripts can be displayed without logging in and only adult scripts are visible. Before, this type of script could still retrieve data through the API of Greasyfork, but now it is no longer possible. |
Ok. Thanks for that context. This does seem reasonable. Two things:
Thanks |
You're right, I have made the necessary changes to the code. |
url: `https://greasyfork.org/scripts/${scriptId}.json`, | ||
}) | ||
} catch (e) { | ||
if (e.message !== 'Not Found') throw e |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could we check for the exception type using instanceof
so it will still work if we customise the not found error.
e.g:
import { NotFound } from '../index.js'
...
if (!(e instanceof NotFound)) throw e
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
okay
🚀 Updated review app: https://pr-9632-badges-shields.fly.dev |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice - thanks
refs #9611