conditional change

This commit is contained in:
pichalite
2016-02-10 10:58:57 -08:00
parent d83b11dde3
commit d81b6947f6

View File

@@ -276,7 +276,7 @@ app.cacheBuster = null;
if (err) {
return app.alertError(err.message);
}
if (!ajaxify.currentPage.match(/^chats\//)) {
if (!ajaxify.currentPage.startsWith('chats/')) {
app.openChat(roomId);
} else {
ajaxify.go('chats/' + roomId);