Merge pull request #1179 from openclassify/vedat

fix certificate error file_get_content
This commit is contained in:
Dia Shalabi 2021-09-30 17:40:20 +03:00 committed by GitHub
commit 60764ffed5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -312,7 +312,15 @@ class AdvRepository extends EntryRepository implements AdvRepositoryInterface
if (!$thumbnail AND $ext[1] != 'svg') {
// Create thumbnail image
$image = Image::make(file_get_contents($adv->files[0]->make()->url()));
$arrContextOptions=array(
"ssl"=>array(
"verify_peer"=>false,
"verify_peer_name"=>false,
),
);
$image = Image::make(file_get_contents($adv->files[0]->make()->url(), false, stream_context_create($arrContextOptions)));
$image->resize(
null,
setting_value('visiosoft.module.advs::thumbnail_height'),