Chore: suggestJump only in production mode (#11082)

pull/10718/merge
Carson 2018-05-09 18:02:47 +08:00 committed by 杨奕
parent 6f2f7aed47
commit a318c5701e
1 changed files with 2 additions and 0 deletions

View File

@ -227,6 +227,8 @@
methods: {
suggestJump() {
if (process.env.NODE_ENV !== 'production') return;
const href = location.href;
const preferGithub = localStorage.getItem('PREFER_GITHUB');
if (href.indexOf('element-cn') > -1 || preferGithub) return;