comments
This commit is contained in:
parent
9bc35363b9
commit
34daad9df7
|
|
@ -117,15 +117,19 @@ function checkProjectVersion({ project }: { project: unknown }): number {
|
|||
}
|
||||
|
||||
const versionValue = project.version;
|
||||
|
||||
// v2 and up
|
||||
if (typeof versionValue === "number") {
|
||||
return versionValue;
|
||||
}
|
||||
|
||||
// v1 (got scenes)
|
||||
const scenesValue = project.scenes;
|
||||
if (Array.isArray(scenesValue) && scenesValue.length > 0) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
// v0 (didn't have scenes)
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue