Skip to content

Commit

Permalink
fix(defineModel): always default modifiers to empty object
Browse files Browse the repository at this point in the history
close #9945
  • Loading branch information
yyx990803 committed Dec 30, 2023
1 parent 4af8583 commit 9bc3c7e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/runtime-core/src/apiSetupHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ export function useModel(
return {
next() {
if (i < 2) {
return { value: i++ ? props[modifierKey] : res, done: false }
return { value: i++ ? props[modifierKey] || {} : res, done: false }
} else {
return { done: true }
}
Expand Down

0 comments on commit 9bc3c7e

Please sign in to comment.