Merge pull request +7453 from c9/fix-vfs-error

Fix protocol change error
pull/117/merge
Tim Robinson 2015-05-29 11:39:02 +02:00
commit 076a351853
1 zmienionych plików z 5 dodań i 1 usunięć

Wyświetl plik

@ -169,8 +169,11 @@ define(function(require, exports, module) {
var servers = shuffleServers(version, vfsServers);
// check for version
if (vfsServers.length && !servers.length)
if (vfsServers.length && !servers.length) {
if (region === "beta")
return callback(fatalError("Staging VFS server(s) not working", "reload"));
return onProtocolChange(callback);
}
var latestServer = 0;
var foundServer = false;
@ -295,6 +298,7 @@ define(function(require, exports, module) {
// I'm keeping this vague because we don't want users to blame
// a "cloud9 update" for losing work
deleteOldVfs();
metrics.increment("vfs.failed.protocol_mismatch", 1, true);
return callback(fatalError("Protocol change detected", "reload"));
}