mirror of
https://github.com/appwrite/appwrite
synced 2026-05-24 01:18:37 +00:00
Catch duplicate db on project create
This commit is contained in:
parent
340aa48d93
commit
73ca1efbeb
1 changed files with 5 additions and 1 deletions
|
|
@ -197,7 +197,11 @@ App::post('/v1/projects')
|
||||||
->setNamespace('_' . $project->getInternalId());
|
->setNamespace('_' . $project->getInternalId());
|
||||||
}
|
}
|
||||||
|
|
||||||
$dbForProject->create();
|
try {
|
||||||
|
$dbForProject->create();
|
||||||
|
} catch (Duplicate) {
|
||||||
|
// Database already exists
|
||||||
|
}
|
||||||
|
|
||||||
$audit = new Audit($dbForProject);
|
$audit = new Audit($dbForProject);
|
||||||
$audit->setup();
|
$audit->setup();
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue