fix: Checks JS window object for null before focusing (#2798)

This commit is contained in:
Nithin David Thomas 2021-08-12 23:21:31 +05:30 committed by GitHub
parent 3d807684bb
commit d492a65c24
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -36,7 +36,7 @@ export default {
methods: {
openLink() {
const win = window.open(this.url, '_blank', 'noopener');
win.focus();
if (win) win.focus();
},
},
};