Skip to content

Commit

Permalink
Fix #240: ignore SSL errors when fetching sitemap from local site wit…
Browse files Browse the repository at this point in the history
…h self-signed certificate.
  • Loading branch information
Tim Cooke committed Aug 5, 2022
1 parent 8e0d160 commit a17c784
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## Unreleased

- [#876](https://github.com/WP2Static/wp2static/pull/876): Fix #240: ignore SSL errors when fetching sitemap from local site with self-signed certificate. @timothylcooke
- [d3977eab](d3977eab6be24c4985d998a7f4bf07409ef4a71b): Create an index on `wp2static_jobs.status`. @john-shaffer
- [#785](https://github.com/leonstafford/wp2static/issues/785): Accept self-signed certs during sitemap crawling. @working-name, @john-shaffer
- [#806](https://github.com/leonstafford/wp2static/pull/806): Detect dead jobs and mark as failed. @john-shaffer
Expand Down
2 changes: 1 addition & 1 deletion src/SitemapParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ protected function getContent() {
if ( ! isset( $this->config['guzzle']['headers']['User-Agent'] ) ) {
$this->config['guzzle']['headers']['User-Agent'] = $this->user_agent;
}
$client = new WP2StaticGuzzleHttp\Client();
$client = new WP2StaticGuzzleHttp\Client( [ 'verify' => false ] );
$res = $client->request( 'GET', $this->current_url, $this->config['guzzle'] );
if ( $res->getStatusCode() === 200 ) {
return $res->getBody()->getContents();
Expand Down

0 comments on commit a17c784

Please sign in to comment.