Skip to content

Commit 5ced668

Browse files
committed
ignore autogenerated recipe fields
1 parent 86de27f commit 5ced668

2 files changed

Lines changed: 16 additions & 10 deletions

File tree

frontend/src/components/RecipeUpdateDialog.vue

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@
120120
<ConfirmDialog
121121
v-model="showAuthConfirm"
122122
title="Update Recipe on Zimfarm"
123-
confirm-text="Authenticate with Zimfarm"
123+
confirm-text="Proceed"
124124
cancel-text="Cancel"
125125
confirm-color="primary"
126126
icon="mdi-information-outline"
@@ -219,15 +219,20 @@ const allDiffs = computed(() => {
219219
}
220220
221221
const differences = diff(oldData, nextData)
222-
return ((differences || []) as EnhancedDiff[])
223-
.filter((d) => d.kind !== undefined)
224-
.map((d) => {
225-
const enhanced: EnhancedDiff = { ...d }
226-
if (d.path && d.path.length > 0 && blobDataKeys.has(String(d.path[0]))) {
227-
enhanced.isBlob = true
228-
}
229-
return enhanced
230-
})
222+
return (
223+
((differences || []) as EnhancedDiff[])
224+
.filter((d) => d.kind !== undefined)
225+
// When a recipe flag is not set (null), its value was auto-computed by the
226+
// scraper. Don't treat that as a difference.
227+
.filter((d) => !(d.kind === 'E' && d.lhs === null))
228+
.map((d) => {
229+
const enhanced: EnhancedDiff = { ...d }
230+
if (d.path && d.path.length > 0 && blobDataKeys.has(String(d.path[0]))) {
231+
enhanced.isBlob = true
232+
}
233+
return enhanced
234+
})
235+
)
231236
})
232237
233238
const diffs = computed(() => {

frontend/src/stores/auth.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,7 @@ export const useAuthStore = defineStore('auth', () => {
380380
const zimfarmProvider = getZimfarmAuthProvider(token.value?.token_type)
381381
await zimfarmProvider.logout()
382382
provider.clearUser()
383+
zimfarmProvider.clearUser()
383384
} catch (error) {
384385
console.error('Error revoking token:', error)
385386
}

0 commit comments

Comments
 (0)