-
Notifications
You must be signed in to change notification settings - Fork 1k
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
[PixivBridge] Rewrite Bridge #2111
Conversation
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.
Hi, @yamanq!
https://feed.eugenemolotov.ru/pr2111/?action=display&bridge=Pixiv&mode=illustrations%2F&tag=doom&posts=10&fullsize=on&format=Html
"On the death road" image does not seem to be fullsize.
bridges/PixivBridge.php
Outdated
|
||
public function collectData() { | ||
$content = getContents($this->getSearchURI()) | ||
or returnClientError('Unable to query pixiv.net'); |
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.
getContents raises exception on non 200 http result. No need to use returnClientError.
bridges/PixivBridge.php
Outdated
} | ||
file_put_contents($path . '/' . $illustId . '.jpeg', $illust); | ||
file_put_contents($path . '/' . $illustId . '.jpg', $illust); |
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.
if $illustId's value is ../../../../etc/rc.local
it could be possible to write outside rss-bridge directory.
You need to escape this situation.
Thanks for the review @em92. I believe all 3 issues are fixed now. I can squash the commits after they are approved. |
gj! |
Rewrite the bridge to use the new site format and added some options:
Closes #1807
Closes #1258