Skip to content
This repository was archived by the owner on Oct 2, 2020. It is now read-only.

Commit 5590ec0

Browse files
committed
fix vue2 issue, bump to v0.2.1
1 parent 98994e0 commit 5590ec0

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

dist/vue-websocket.js

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/vue-websocket.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "vue-websocket",
3-
"version": "0.2.0",
3+
"version": "0.2.1",
44
"description": "Websocket handler for Vue.js",
55
"homepage": "https://github.com/icebob/vue-websocket",
66
"main": "dist/vue-websocket.js",

src/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export default {
1414
Vue.prototype.$socket = socket;
1515

1616
let addListeners = function() {
17-
if (this.$options.hasOwnProperty("socket")) {
17+
if (this.$options["socket"]) {
1818
let conf = this.$options.socket;
1919
if (conf.namespace) {
2020
this.$socket = IO(conf.namespace, conf.options);
@@ -32,7 +32,7 @@ export default {
3232
};
3333

3434
let removeListeners = function() {
35-
if (this.$options.hasOwnProperty("socket")) {
35+
if (this.$options["socket"]) {
3636
let conf = this.$options.socket;
3737

3838
if (conf.namespace) {

0 commit comments

Comments
 (0)