From b49713a0967dd91e402ffd0bf9c3334316af5fa7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Tue, 29 Aug 2017 20:53:50 +0200 Subject: [PATCH] Fix Maximum Call Size Stack --- lib/app/utils.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/app/utils.js b/lib/app/utils.js index 4b13d6daf8..2ad110a906 100644 --- a/lib/app/utils.js +++ b/lib/app/utils.js @@ -11,16 +11,16 @@ if (process.browser) { } } -export function applyAsyncData (Component, asyncData = {}) { +export function applyAsyncData (Component, asyncData) { const ComponentData = Component.options.data || noopData // Prevent calling this method for each request on SSR context - if(!asyncData && Component.options.hasAsyncData) { + if (!asyncData && Component.options.hasAsyncData) { return } Component.options.hasAsyncData = true Component.options.data = function () { const data = ComponentData.call(this) - if(this.$ssrContext) { + if (this.$ssrContext) { asyncData = this.$ssrContext.asyncData[Component.cid] } return { ...data, ...asyncData }