Skip to content

Commit 7350755

Browse files
committed
bump
1 parent 8d9c323 commit 7350755

3 files changed

Lines changed: 9 additions & 11 deletions

File tree

OpenFlow/src/public/CommonControllers.ts

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,15 +32,12 @@ module openflow {
3232
this.gettoken();
3333
// cleanup();
3434
});
35-
var cleanup2 = this.$rootScope.$on('cordovadetected', (event, data) => {
36-
if (event && data) { }
37-
console.log("cordovadetected, reload token");
38-
this.gettoken();
39-
cleanup2();
40-
});
41-
42-
43-
35+
// var cleanup2 = this.$rootScope.$on('cordovadetected', (event, data) => {
36+
// if (event && data) { }
37+
// console.log("cordovadetected, reload token");
38+
// this.gettoken();
39+
// cleanup2();
40+
// });
4441
['log', 'warn', 'debug', 'error'].forEach((methodName) => {
4542
//['error2'].forEach((methodName) => {
4643
const originalMethod = console[methodName];

OpenFlow/src/public/WebSocketClient.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ module openflow {
150150
});
151151
}
152152
scanForCordova() {
153+
if (this.usingCordova == true) return;
153154
try {
154155
if (cordova !== undefined) {
155156
console.log("Found cordova");
@@ -233,7 +234,6 @@ module openflow {
233234
}
234235
}
235236
init() {
236-
setTimeout(this.scanForCordova.bind(this), 200);
237237
this.getJSON("/config", async (error: any, data: any) => {
238238
var parser = document.createElement('a');
239239
parser.href = data.wshost;
@@ -320,6 +320,7 @@ module openflow {
320320
private onopen(evt: Event) {
321321
// console.debug("WebSocketClient::onopen: connected");
322322
this.$rootScope.$broadcast("socketopen");
323+
setTimeout(this.scanForCordova.bind(this), 200);
323324
}
324325
private onclose(evt: CloseEvent): void {
325326
var me: WebSocketClient = WebSocketClient.instance;

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0.0.262
1+
0.0.263

0 commit comments

Comments
 (0)