From: Austin Keener Date: Sun, 4 Jul 2021 22:32:44 +0000 (-0400) Subject: fix(compat): fix props check for v-model compat warning (#4056) X-Git-Tag: v3.1.5~28 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f3e15f633edfa2d4f116bf52fd5dee02655567e3;p=thirdparty%2Fvuejs%2Fcore.git fix(compat): fix props check for v-model compat warning (#4056) --- diff --git a/packages/runtime-core/src/compat/compatConfig.ts b/packages/runtime-core/src/compat/compatConfig.ts index a6ab9854bb..05ecc3e72e 100644 --- a/packages/runtime-core/src/compat/compatConfig.ts +++ b/packages/runtime-core/src/compat/compatConfig.ts @@ -398,9 +398,10 @@ export const deprecationData: Record = { DeprecationTypes.COMPONENT_V_MODEL }: false }\`.` if ( - comp.props && isArray(comp.props) + comp.props && + (isArray(comp.props) ? comp.props.includes('modelValue') - : hasOwn(comp.props, 'modelValue') + : hasOwn(comp.props, 'modelValue')) ) { return ( `Component delcares "modelValue" prop, which is Vue 3 usage, but ` +