Skip to content

Commit

Permalink
fix: fix server env detection in wechat mini program (vuejs#9075)
Browse files Browse the repository at this point in the history
  • Loading branch information
fjc0k authored and hefeng committed Jan 25, 2019
1 parent 8e99630 commit c35f88e
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 c35f88e

Please sign in to comment.