Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: disallow clone toggle on change request enabled #3383

Merged
merged 4 commits into from
Mar 27, 2023

Conversation

kwasniew
Copy link
Contributor

@kwasniew kwasniew commented Mar 24, 2023

About the changes

Screenshot 2023-03-24 at 15 24 04

Prevent clone of toggle in one project when this project has change requests enabled in any environment.
Previously we were cloning the feature and then we got error on change request strategies clone.
Now blocking is done in the UI and in the backend.

Important files

Discussion points

@vercel
Copy link

vercel bot commented Mar 24, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated
unleash-monorepo-frontend ✅ Ready (Inspect) Visit Preview 💬 Add your feedback Mar 27, 2023 at 9:42AM (UTC)
1 Ignored Deployment
Name Status Preview Comments Updated
unleash-docs ⬜️ Ignored (Inspect) Mar 27, 2023 at 9:42AM (UTC)

Copy link
Contributor

@FredrikOseberg FredrikOseberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@@ -372,7 +399,7 @@ test('Cloning a feature toggle also clones segments correctly', async () => {

let feature = await service.getFeature({ featureName: clonedFeatureName });
expect(
feature.environments.find((x) => x.name === 'default').strategies[0]
feature.environments.find((x) => x.name === 'default')?.strategies[0]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
feature.environments.find((x) => x.name === 'default')?.strategies[0]
feature.environments.find((environment) => environment.name === 'default')?.strategies[0]

@kwasniew kwasniew merged commit 2caab45 into main Mar 27, 2023
@kwasniew kwasniew deleted the disallow-clone-feature-on-cr-enabled branch March 27, 2023 11:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants