This commit is contained in:
Jérémy Munsch 2023-10-06 16:31:06 +02:00
parent e96da4a22a
commit 23c9efdb22
No known key found for this signature in database
GPG key ID: 18361AF3BFEC0FEC
4 changed files with 1 additions and 5 deletions

View file

@ -153,7 +153,6 @@ class CustomerController extends Controller
// * Make sure we are accessing a customer that belongs to our service.
$this->authorize('customerBelongsToService', $customer);
// TODO: Gestion avec mesBR.
/** @var \App\Models\CustomerInfo */
$customerInfo = $customer->info($service->brand, Customer::FIRST_OR_FAIL);
/** @var \App\Models\CustomerLogin */

View file

@ -153,7 +153,6 @@ class CustomerController extends Controller
// * Make sure we are accessing a customer that belongs to our service.
$this->authorize('customerBelongsToService', $customer);
// TODO: Gestion avec mesBR.
/** @var \App\Models\CustomerInfo */
$customerInfo = $customer->info($service->brand, Customer::FIRST_OR_FAIL);
/** @var \App\Models\CustomerLogin */

View file

@ -147,7 +147,6 @@ class CustomerController extends Controller
public function delete(Customer $customer, Brand $brand): \Illuminate\Http\RedirectResponse
{
try {
// TODO: Gestion avec mesBR.
/** @var \App\Models\CustomerInfo */
$customerInfo = $customer->info($brand, Customer::FIRST_OR_FAIL);
/** @var \App\Models\CustomerLogin */

View file

@ -186,9 +186,8 @@ class Service extends Model
/** @var \App\Models\Service $service */
foreach ($services as $service) {
$tokenEquals = false;
// * Keep compatibility with V1.
// * Keep compatibility with V2.
if (!Hash::needsRehash($bearerToken)) {
// TODO: Remove this method when no more service will be in V1 (hashed instead of encrypted).
$tokenEquals = Hash::check($bearerToken, $service->bearer_token);
} else {
$tokenEquals = $bearerToken === $service->bearer_token;