fixed paddle api client
This commit is contained in:
@@ -70,6 +70,7 @@ class PaddleClient
|
||||
$headers = [
|
||||
'User-Agent' => sprintf('FotospielApp/%s PaddleClient', app()->version()),
|
||||
'Paddle-Environment' => Str::lower($environment) === 'sandbox' ? 'sandbox' : 'production',
|
||||
'Paddle-Version' => '1',
|
||||
];
|
||||
|
||||
return $this->http
|
||||
|
||||
@@ -32,6 +32,8 @@ class BillingPortalTest extends TenantTestCase
|
||||
$response->assertOk();
|
||||
$response->assertJsonPath('url', 'https://portal.example/overview');
|
||||
|
||||
Http::assertSent(fn (Request $request) => $request->hasHeader('Paddle-Version', '1'));
|
||||
|
||||
$this->assertDatabaseHas('tenants', [
|
||||
'id' => $this->tenant->id,
|
||||
'paddle_customer_id' => 'cus_123',
|
||||
|
||||
Reference in New Issue
Block a user