mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
[bugfix] render is crashed while this.$vantMessages is undefined
This commit is contained in:
parent
d17f0923cd
commit
4c7c2d7b76
@ -7,8 +7,10 @@ export default {
|
||||
const { name } = this.$options;
|
||||
const prefix = name ? camelize(name) + '.' : '';
|
||||
|
||||
if (process.env.NODE_ENV !== 'production' && !this.$vantMessages) {
|
||||
console.warn('[Vant] Locale not correctly registered.');
|
||||
if (!this.$vantMessages) {
|
||||
if (process.env.NODE_ENV !== 'production') {
|
||||
console.warn('[Vant] Locale not correctly registered.');
|
||||
}
|
||||
return () => '';
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user