mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-22 08:02:19 +00:00
Fix ignore confirmation modal if no changes (#4725)
This commit is contained in:
+10
-2
@@ -4,7 +4,12 @@
|
||||
import { goto as gotoUrl } from '$app/navigation'
|
||||
import Button from '../button/Button.svelte'
|
||||
import type DiffDrawer from '$lib/components/DiffDrawer.svelte'
|
||||
import { cleanValueProperties, orderedJsonStringify, type Value } from '$lib/utils'
|
||||
import {
|
||||
cleanValueProperties,
|
||||
orderedJsonStringify,
|
||||
replaceFalseWithUndefined,
|
||||
type Value
|
||||
} from '$lib/utils'
|
||||
import { tick } from 'svelte'
|
||||
import { page } from '$app/stores'
|
||||
|
||||
@@ -36,7 +41,10 @@
|
||||
path: undefined
|
||||
})
|
||||
const current = cleanValueProperties({ ...(modifiedValue ?? {}), path: undefined })
|
||||
if (orderedJsonStringify(draftOrDeployed) === orderedJsonStringify(current)) {
|
||||
if (
|
||||
orderedJsonStringify(replaceFalseWithUndefined(draftOrDeployed)) ===
|
||||
orderedJsonStringify(replaceFalseWithUndefined(current))
|
||||
) {
|
||||
bypassBeforeNavigate = true
|
||||
gotoUrl(goingTo)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user