Skip to content

Commit

Permalink
fix warning (php 5.6)
Browse files Browse the repository at this point in the history
  • Loading branch information
deemru committed Feb 15, 2021
1 parent 491ad01 commit aaed0b1
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/WavesKit.php
Original file line number Diff line number Diff line change
Expand Up @@ -576,12 +576,15 @@ private function fetchInit( $address, $doConnect )

if( !isset( $this->curlOptions ) )
{
if( !defined( 'WK_CURL_OPTIONS' ) )
define( 'WK_CURL_OPTIONS', [] );

$this->curlOptions = [];
foreach( WK_CURL_OPTIONS as $k => $v )
$this->curlOptions[$k] = $v;

if( PHP_MAJOR_VERSION > 5 )
{
if( !defined( 'WK_CURL_OPTIONS' ) )
define( 'WK_CURL_OPTIONS', [] );
foreach( WK_CURL_OPTIONS as $k => $v )
$this->curlOptions[$k] = $v;
}
}

foreach( $this->curlOptions as $k => $v )
Expand Down

0 comments on commit aaed0b1

Please sign in to comment.