Skip to content

Commit

Permalink
fix: fix server env detection in wechat mini program (#9075)
Browse files Browse the repository at this point in the history
  • Loading branch information
fjc0k authored and yyx990803 committed Dec 1, 2018
1 parent 1129d18 commit 05e8bcf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/util/env.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export const isServerRendering = () => {
if (!inBrowser && !inWeex && typeof global !== 'undefined') {
// detect presence of vue-server-renderer and avoid
// Webpack shimming the process
_isServer = global['process'].env.VUE_ENV === 'server'
_isServer = global['process'] && global['process'].env.VUE_ENV === 'server'
} else {
_isServer = false
}
Expand Down

0 comments on commit 05e8bcf

Please sign in to comment.