mirror of
https://github.com/archtechx/tenancy.git
synced 2025-12-13 02:54:05 +00:00
Apply fixes from StyleCI
This commit is contained in:
parent
c20942cda5
commit
311df11d0b
1 changed files with 3 additions and 1 deletions
|
|
@ -88,7 +88,7 @@ class RedisStorageDriver implements StorageDriver
|
||||||
foreach ($tenant->domains as $domain) {
|
foreach ($tenant->domains as $domain) {
|
||||||
$pipe->del("domains:$domain");
|
$pipe->del("domains:$domain");
|
||||||
}
|
}
|
||||||
|
|
||||||
$pipe->del("tenants:{$tenant->id}");
|
$pipe->del("tenants:{$tenant->id}");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
@ -121,12 +121,14 @@ class RedisStorageDriver implements StorageDriver
|
||||||
public function get(string $key, Tenant $tenant = null)
|
public function get(string $key, Tenant $tenant = null)
|
||||||
{
|
{
|
||||||
$tenant = $tenant ?? $this->tenant();
|
$tenant = $tenant ?? $this->tenant();
|
||||||
|
|
||||||
return json_decode($this->redis->hget("tenants:{$tenant->id}", $key), true);
|
return json_decode($this->redis->hget("tenants:{$tenant->id}", $key), true);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getMany(array $keys, Tenant $tenant = null): array
|
public function getMany(array $keys, Tenant $tenant = null): array
|
||||||
{
|
{
|
||||||
$tenant = $tenant ?? $this->tenant();
|
$tenant = $tenant ?? $this->tenant();
|
||||||
|
|
||||||
return $this->redis->hmget("tenants:{$tenant->id}", $keys);
|
return $this->redis->hmget("tenants:{$tenant->id}", $keys);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue