Skip to content

Commit f8d48ee

Browse files
committed
Revert prisma create-new-database-in-existing-project action to upstream master version
1 parent c8da5c4 commit f8d48ee

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

components/prisma_management_api/actions/create-new-database-in-existing-project/create-new-database-in-existing-project.mjs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,14 +36,16 @@ export default {
3636
if (!this.region) {
3737
throw new Error("Region is required for creating a database");
3838
}
39+
40+
const data = {
41+
region: this.region,
42+
};
43+
if (this.isDefault !== undefined) data.default = this.isDefault;
3944

4045
const response = await this.app.createDatabase({
4146
$,
4247
projectId: this.projectId,
43-
data: {
44-
region: this.region,
45-
default: this.isDefault,
46-
},
48+
data,
4749
});
4850

4951
if (response) {

0 commit comments

Comments
 (0)