@openfn/project 0.13.0 → 0.13.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -0
- package/dist/index.js +3 -3
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -64,7 +64,7 @@ function to_app_state_default(project, options = {}) {
|
|
|
64
64
|
pick(project, ["name", "description", "collections"]),
|
|
65
65
|
isNil
|
|
66
66
|
);
|
|
67
|
-
state.id = uuid;
|
|
67
|
+
state.id = uuid ?? randomUUID();
|
|
68
68
|
Object.assign(state, rest, project.options);
|
|
69
69
|
state.project_credentials = project.credentials ?? [];
|
|
70
70
|
state.workflows = project.workflows.map(mapWorkflow).reduce((obj, wf) => {
|
|
@@ -894,8 +894,8 @@ var parseProject = async (options) => {
|
|
|
894
894
|
const context = loadWorkspaceFile(content, type);
|
|
895
895
|
const config = buildConfig(options.config ?? context.workspace);
|
|
896
896
|
const proj = {
|
|
897
|
-
id: context.project?.id,
|
|
898
|
-
name: context.project?.name,
|
|
897
|
+
id: options.name ? slugify(options.name) : context.project?.id,
|
|
898
|
+
name: options.name ? slugify(options.name) : context.project?.name,
|
|
899
899
|
openfn: omit2(context.project, ["id", "forked_from"]),
|
|
900
900
|
config,
|
|
901
901
|
workflows: [],
|