Skip to content

Commit bc3ade9

Browse files
committed
fix: update tenancy namespace
1 parent 461f35f commit bc3ade9

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

src/Bucket.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
use Aws\Exception\AwsException;
77
use Aws\S3\S3Client;
88
use Illuminate\Support\Facades\Log;
9-
use Stancl\Tenancy\Contracts\TenantWithDatabase;
9+
use Stancl\Tenancy\Contracts\Tenant;
1010
use Vidwan\TenantBuckets\Events\CreatedBucket;
1111
use Vidwan\TenantBuckets\Events\CreatingBucket;
1212
use Vidwan\TenantBuckets\Events\DeletedBucket;
@@ -47,7 +47,7 @@ class Bucket
4747
protected AwsException|null $e;
4848

4949
public function __construct(
50-
protected TenantWithDatabase $tenant
50+
protected Tenant $tenant
5151
) {
5252
$this->setupCredentials();
5353
}
@@ -93,7 +93,7 @@ public function deleteTenantBucket(): self
9393
* Create a New Bucket
9494
*
9595
* @param string $name Name of the S3 Bucket
96-
* @param Aws\Credentials\Credentials $credentials AWS Credentials Object
96+
* @param \Aws\Credentials\Credentials $credentials AWS Credentials Object
9797
* @access public
9898
* @return self $this
9999
*/
@@ -134,7 +134,7 @@ public function createBucket(string $name, Credentials $credentials): self
134134
* Create a New Bucket
135135
*
136136
* @param string $name Name of the S3 Bucket
137-
* @param Aws\Credentials\Credentials $credentials AWS Credentials Object
137+
* @param \Aws\Credentials\Credentials $credentials AWS Credentials Object
138138
* @access public
139139
* @return self $this
140140
*/
@@ -180,7 +180,7 @@ public function getBucketName(): string|null
180180
}
181181

182182
/**
183-
* Get Error Messsge
183+
* Get Error Message
184184
*
185185
* @return string|null
186186
*/
@@ -198,6 +198,6 @@ public function getErrorMessage(): string|null
198198
*/
199199
public function getErrorBag(): AwsException|null
200200
{
201-
return $this->e ? $this->e : null;
201+
return $this->e ?: null;
202202
}
203203
}

src/Jobs/CreateTenantBucket.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
use Illuminate\Foundation\Bus\Dispatchable;
88
use Illuminate\Queue\InteractsWithQueue;
99
use Illuminate\Queue\SerializesModels;
10-
use Stancl\Tenancy\Contracts\TenantWithDatabase;
10+
use Stancl\Tenancy\Contracts\Tenant;
1111
use Vidwan\TenantBuckets\Bucket;
1212

1313
class CreateTenantBucket implements ShouldQueue
@@ -42,7 +42,7 @@ class CreateTenantBucket implements ShouldQueue
4242
*
4343
* @return void
4444
*/
45-
public function __construct(TenantWithDatabase $tenant)
45+
public function __construct(Tenant $tenant)
4646
{
4747
//
4848
$this->tenant = $tenant;

src/Jobs/DeleteTenantBucket.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
use Illuminate\Foundation\Bus\Dispatchable;
88
use Illuminate\Queue\InteractsWithQueue;
99
use Illuminate\Queue\SerializesModels;
10-
use Stancl\Tenancy\Contracts\TenantWithDatabase;
10+
use Stancl\Tenancy\Contracts\Tenant;
1111
use Vidwan\TenantBuckets\Bucket;
1212

1313
class DeleteTenantBucket implements ShouldQueue
@@ -42,7 +42,7 @@ class DeleteTenantBucket implements ShouldQueue
4242
*
4343
* @return void
4444
*/
45-
public function __construct(TenantWithDatabase $tenant)
45+
public function __construct(Tenant $tenant)
4646
{
4747
//
4848
$this->tenant = $tenant;

0 commit comments

Comments
 (0)