style:run linter

This commit is contained in:
Everly Precia Suresh 2022-10-25 19:26:15 +00:00
parent f055e15031
commit cd0a5b73f8

View file

@ -98,10 +98,13 @@ class DatabaseV1 extends Worker
$dbForProject->updateDocument('attributes', $attribute->getId(), $attribute->setAttribute('status', 'available'));
} catch (\Throwable $th) {
Console::error($th->getMessage());
$dbForProject->updateDocument('attributes', $attribute->getId(),
$attribute
->setAttribute('status', 'failed')
->setAttribute('error', $th->getMessage()));
$dbForProject->updateDocument(
'attributes',
$attribute->getId(),
$attribute
->setAttribute('status', 'failed')
->setAttribute('error', $th->getMessage())
);
} finally {
$target = Realtime::fromPayload(
// Pass first, most verbose event pattern
@ -161,11 +164,13 @@ class DatabaseV1 extends Worker
$dbForProject->deleteDocument('attributes', $attribute->getId());
} catch (\Throwable $th) {
Console::error($th->getMessage());
$dbForProject->updateDocument('attributes', $attribute->getId(),
$attribute
->setAttribute('status', 'stuck')
->setAttribute('error', $th->getMessage())
);
$dbForProject->updateDocument(
'attributes',
$attribute->getId(),
$attribute
->setAttribute('status', 'stuck')
->setAttribute('error', $th->getMessage())
);
} finally {
$target = Realtime::fromPayload(
// Pass first, most verbose event pattern
@ -275,11 +280,13 @@ class DatabaseV1 extends Worker
$dbForProject->updateDocument('indexes', $index->getId(), $index->setAttribute('status', 'available'));
} catch (\Throwable $th) {
Console::error($th->getMessage());
$dbForProject->updateDocument('indexes', $index->getId(),
$index
->setAttribute('status', 'failed')
->setAttribute('error', $th->getMessage())
);
$dbForProject->updateDocument(
'indexes',
$index->getId(),
$index
->setAttribute('status', 'failed')
->setAttribute('error', $th->getMessage())
);
} finally {
$target = Realtime::fromPayload(
// Pass first, most verbose event pattern
@ -332,12 +339,13 @@ class DatabaseV1 extends Worker
$dbForProject->deleteDocument('indexes', $index->getId());
} catch (\Throwable $th) {
Console::error($th->getMessage());
$dbForProject->updateDocument('indexes', $index->getId(),
$index
->setAttribute('status', 'stuck')
->setAttribute('error',$th->getMessage())
);
$dbForProject->updateDocument(
'indexes',
$index->getId(),
$index
->setAttribute('status', 'stuck')
->setAttribute('error', $th->getMessage())
);
} finally {
$target = Realtime::fromPayload(
// Pass first, most verbose event pattern