From 67b3113693e409bef9ca3a0d26e0f3c05ca2ae11 Mon Sep 17 00:00:00 2001 From: tomasciccola <117094913+tomasciccola@users.noreply.github.com> Date: Tue, 20 Aug 2024 12:18:06 -0300 Subject: [PATCH] add `isInitialProject` to `ProjectSettings` (#215) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Tomás Ciccola --- proto/projectSettings/v1.proto | 1 + schema/projectSettings/v1.json | 6 +++++- test/fixtures/good-docs-completed.js | 1 + test/fixtures/good-docs-minimal.js | 1 + 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/proto/projectSettings/v1.proto b/proto/projectSettings/v1.proto index 324eace..43fd57f 100644 --- a/proto/projectSettings/v1.proto +++ b/proto/projectSettings/v1.proto @@ -30,4 +30,5 @@ message ProjectSettings_1 { optional DefaultPresets defaultPresets = 2; optional ConfigMetadata configMetadata = 3; optional string name = 4; + bool isInitialProject = 5; } diff --git a/schema/projectSettings/v1.json b/schema/projectSettings/v1.json index 9e715f1..07d6e26 100644 --- a/schema/projectSettings/v1.json +++ b/schema/projectSettings/v1.json @@ -49,8 +49,12 @@ }, "additionalProperties": false, "required": ["name", "buildDate", "importDate", "fileVersion"] + }, + "isInitialProject": { + "type": "boolean", + "description": "this allows for checking if the user has already joined a project or if its on the initial 'default' project" } }, - "required": ["schemaName"], + "required": ["schemaName", "isInitialProject"], "additionalProperties": false } diff --git a/test/fixtures/good-docs-completed.js b/test/fixtures/good-docs-completed.js index 074f4d9..4afd35a 100644 --- a/test/fixtures/good-docs-completed.js +++ b/test/fixtures/good-docs-completed.js @@ -97,6 +97,7 @@ export const goodDocsCompleted = [ buildDate: cachedValues.configMetadata.buildDate, importDate: cachedValues.configMetadata.importDate, }, + isInitialProject: true, deleted: false, }, expected: {}, diff --git a/test/fixtures/good-docs-minimal.js b/test/fixtures/good-docs-minimal.js index 24b50f6..caf2143 100644 --- a/test/fixtures/good-docs-minimal.js +++ b/test/fixtures/good-docs-minimal.js @@ -44,6 +44,7 @@ export const goodDocsMinimal = [ }, links: [], deleted: false, + isInitialProject: false, }, expected: {}, },