mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fix bad UUID generation.
This commit is contained in:
parent
b7f48a19e8
commit
b54ef9f5e5
@ -17,9 +17,15 @@ trait GeneratesInstallationId
|
||||
protected function generateInstallationId(): void
|
||||
{
|
||||
$config = app('fireflyconfig')->get('installation_id', null);
|
||||
|
||||
// delete if wrong UUID:
|
||||
if (null !== $config && 'b2c27d92-be90-5c10-8589-005df5b314e6' === $config->data) {
|
||||
$config = null;
|
||||
}
|
||||
|
||||
if (null === $config) {
|
||||
$uuid5 = Uuid::uuid5(Uuid::NAMESPACE_URL, 'firefly-iii.org');
|
||||
$uniqueId = (string) $uuid5;
|
||||
$uuid4 = Uuid::uuid4();
|
||||
$uniqueId = (string) $uuid4;
|
||||
Log::info(sprintf('Created Firefly III installation ID %s', $uniqueId));
|
||||
app('fireflyconfig')->set('installation_id', $uniqueId);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user