Skip to content
This repository was archived by the owner on Jun 14, 2019. It is now read-only.

Commit 826dcaf

Browse files
committed
Release 2.0.3
1 parent 2ade73a commit 826dcaf

File tree

5 files changed

+38
-14
lines changed

5 files changed

+38
-14
lines changed

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,13 @@
1+
<a name"2.0.3"></a>
2+
### 2.0.3 (2015-06-22)
3+
4+
5+
#### Bug Fixes
6+
7+
* **demo:** Replace CoffeeScript w/ BabelJS runner ([4dc71a07](https://github.com/knalli/angular-vertxbus/commit/4dc71a07))
8+
* **service:** fix doubled handler registration in special circumstances ([f3311ca5](https://github.com/knalli/angular-vertxbus/commit/f3311ca5))
9+
10+
111
<a name"2.0.2"></a>
212
### 2.0.2 (2015-06-15)
313

dist/angular-vertxbus.js

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
/*! angular-vertxbus - v2.0.2 - 2015-06-15
1+
/*! angular-vertxbus - v2.0.3 - 2015-06-22
22
* http://github.com/knalli/angular-vertxbus
33
* Copyright (c) 2015 Jan Philipp; Licensed MIT */
44
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
@@ -615,13 +615,19 @@ var LiveDelegate = (function (_BaseDelegate) {
615615

616616
// internal
617617
value: function onEventbusOpen() {
618+
var connectionStateFlipped = false;
618619
this.getConnectionState(true);
619620
if (!this.states.connected) {
620621
this.states.connected = true;
621-
this.$rootScope.$broadcast('' + this.options.prefix + 'system.connected');
622+
connectionStateFlipped = true;
622623
}
624+
// Ensure all events will be re-attached
623625
this.afterEventbusConnected();
624-
this.$rootScope.$digest();
626+
// Everything is online and registered again, let's notify everybody
627+
if (connectionStateFlipped) {
628+
this.$rootScope.$broadcast('' + this.options.prefix + 'system.connected');
629+
}
630+
this.$rootScope.$digest(); // explicitly
625631
// consume message queue?
626632
if (this.options.messageBuffer && this.messageQueue.size()) {
627633
while (this.messageQueue.size()) {
@@ -718,6 +724,7 @@ var LiveDelegate = (function (_BaseDelegate) {
718724
}
719725
if (this.options.debugEnabled) {
720726
this.$log.debug('[Vert.x EB Service] Register handler for ' + address);
727+
console.trace();
721728
}
722729
var callbackWrapper = function callbackWrapper(message, replyTo) {
723730
callback(message, replyTo);
@@ -1323,7 +1330,7 @@ var EventbusWrapper = (function (_BaseWrapper) {
13231330
_this.disconnectTimeoutEnabled = true;
13241331
_this.connect();
13251332
} else if (_this.options.reconnectEnabled) {
1326-
// automatical reconnect after timeout
1333+
// automatic reconnect after timeout
13271334
if (_this.options.debugEnabled) {
13281335
_this.$log.debug('[Vert.x EB Stub] Reconnect in ' + _this.options.sockjsReconnectInterval + 'ms');
13291336
}

0 commit comments

Comments
 (0)