From a9abbfe932453702704eb0a5e593f23294d3e203 Mon Sep 17 00:00:00 2001 From: Eduardo Bacarin Date: Fri, 4 Jul 2025 16:57:17 -0300 Subject: [PATCH] setted server url as a class property and consumes it in every function --- src/Kore.php | 2 +- src/Pix.php | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/Kore.php b/src/Kore.php index 8549a08..22347e9 100644 --- a/src/Kore.php +++ b/src/Kore.php @@ -6,7 +6,7 @@ use phpseclib3\Crypt\PublicKeyLoader; class Kore { - private $url = 'https://httpbin.org'; + public $url = 'https://httpbin.org'; public $privateKey; public $drone; public function __construct($privateKey, $drone) { diff --git a/src/Pix.php b/src/Pix.php index 0561dfe..23c97bc 100644 --- a/src/Pix.php +++ b/src/Pix.php @@ -32,7 +32,7 @@ class Pix extends Kore } return curlRequest( - 'https://httpbin.org/post', + $this->url . '/post', 'POST', [], [ @@ -69,7 +69,7 @@ class Pix extends Kore } return curlRequest( - 'https://httpbin.org/post', + $this->url . '/post', 'POST', [], [ @@ -114,7 +114,7 @@ class Pix extends Kore } return curlRequest( - 'https://httpbin.org/post', + $this->url . '/post', 'POST', [], [ @@ -158,7 +158,7 @@ class Pix extends Kore } return curlRequest( - 'https://httpbin.org/post', + $this->url . '/post', 'POST', [], [