From 679d48c8c02b188a69c04bee4a8dedd8a208f669 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Chopin?= Date: Tue, 14 Nov 2017 10:28:18 +0100 Subject: [PATCH] Update router.js --- lib/app/router.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/app/router.js b/lib/app/router.js index e7f997d7e3..efad4256db 100644 --- a/lib/app/router.js +++ b/lib/app/router.js @@ -60,8 +60,8 @@ export function createRouter () { routes: [ <%= _routes %> ], - parseQuery: <%= router.parseQuery %>, - stringifyQuery: <%= router.stringifyQuery %>, + <% if (router.parseQuery) { %>parseQuery: <%= serialize(router.parseQuery).replace('parseQuery(', 'function(') %>,<% } %> + <% if (router.stringifyQuery) { %>stringifyQuery: <%= serialize(router.stringifyQuery).replace('stringifyQuery(', 'function(') %>,<% } %> fallback: <%= router.fallback %> }) }