Skip to content

Commit

Permalink
Mark setting as optional
Browse files Browse the repository at this point in the history
  • Loading branch information
sebelga committed Sep 17, 2024
1 parent ae3f884 commit 5ea166d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
12 changes: 7 additions & 5 deletions x-pack/plugins/spaces/server/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,13 @@ export const ConfigSchema = schema.object({
defaultValue: true,
}),
}),
experimental: offeringBasedSchema({
traditional: schema.object({
forceSolutionVisibility: schema.boolean({ defaultValue: false }),
}),
}),
experimental: schema.maybe(
offeringBasedSchema({
traditional: schema.object({
forceSolutionVisibility: schema.boolean({ defaultValue: false }),
}),
})
),
});

export function createConfig$(context: PluginInitializerContext) {
Expand Down
2 changes: 1 addition & 1 deletion x-pack/plugins/spaces/server/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ export class SpacesPlugin
// unless the forceSolutionVisibility flag is set.
allowSolutionVisibility:
(onCloud && config.allowSolutionVisibility) ||
config.experimental.forceSolutionVisibility,
Boolean(config.experimental?.forceSolutionVisibility),
})
)
);
Expand Down

0 comments on commit 5ea166d

Please sign in to comment.