diff --git a/CHANGES.rst b/CHANGES.rst index 08efbbf24..78c178baf 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -1,3 +1,19 @@ +Changes in synapse 0.4.2 (2014-10-31) +===================================== + +Homeserver: + * Fix bugs where we did not notify users of correct presence updates. + * Fix bug where we did not handle sub second event stream timeouts. + +Webclient: + * Add ability to click on messages to see JSON. + * Add ability to redact messages. + * Add ability to view and edit all room state JSON. + * Handle incoming redactions. + * Improve feedback on errors. + * Fix bugs in mobile CSS. + * Fix bugs with desktop notifications. + Changes in synapse 0.4.1 (2014-10-17) ===================================== Webclient: diff --git a/VERSION b/VERSION index 267577d47..2b7c5ae01 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.4.1 +0.4.2 diff --git a/synapse/__init__.py b/synapse/__init__.py index 7067188c5..23ae5f003 100644 --- a/synapse/__init__.py +++ b/synapse/__init__.py @@ -16,4 +16,4 @@ """ This is a reference implementation of a synapse home server. """ -__version__ = "0.4.1" +__version__ = "0.4.2" diff --git a/synapse/handlers/register.py b/synapse/handlers/register.py index 88eb51a8e..7df9d9b82 100644 --- a/synapse/handlers/register.py +++ b/synapse/handlers/register.py @@ -15,7 +15,6 @@ """Contains functions for registering clients.""" from twisted.internet import defer -from twisted.python import log from synapse.types import UserID from synapse.api.errors import ( @@ -129,7 +128,7 @@ class RegistrationHandler(BaseHandler): try: threepid = yield self._threepid_from_creds(c) except: - log.err() + logger.exception("Couldn't validate 3pid") raise RegistrationError(400, "Couldn't validate 3pid") if not threepid: diff --git a/webclient/app.js b/webclient/app.js index 8d9b662ee..c091f8c6c 100644 --- a/webclient/app.js +++ b/webclient/app.js @@ -30,6 +30,7 @@ var matrixWebClient = angular.module('matrixWebClient', [ 'MatrixCall', 'eventStreamService', 'eventHandlerService', + 'notificationService', 'infinite-scroll', 'ui.bootstrap', 'monospaced.elastic' diff --git a/webclient/components/matrix/event-handler-service.js b/webclient/components/matrix/event-handler-service.js index 6f251eec5..e63584510 100644 --- a/webclient/components/matrix/event-handler-service.js +++ b/webclient/components/matrix/event-handler-service.js @@ -27,8 +27,8 @@ Typically, this service will store events or broadcast them to any listeners if typically all the $on method would do is update its own $scope. */ angular.module('eventHandlerService', []) -.factory('eventHandlerService', ['matrixService', '$rootScope', '$q', '$timeout', 'mPresence', -function(matrixService, $rootScope, $q, $timeout, mPresence) { +.factory('eventHandlerService', ['matrixService', '$rootScope', '$q', '$timeout', 'mPresence', 'notificationService', +function(matrixService, $rootScope, $q, $timeout, mPresence, notificationService) { var ROOM_CREATE_EVENT = "ROOM_CREATE_EVENT"; var MSG_EVENT = "MSG_EVENT"; var MEMBER_EVENT = "MEMBER_EVENT"; @@ -45,71 +45,6 @@ function(matrixService, $rootScope, $q, $timeout, mPresence) { var eventMap = {}; $rootScope.presence = {}; - - // TODO: This is attached to the rootScope so .html can just go containsBingWord - // for determining classes so it is easy to highlight bing messages. It seems a - // bit strange to put the impl in this service though, but I can't think of a better - // file to put it in. - $rootScope.containsBingWord = function(content) { - if (!content || $.type(content) != "string") { - return false; - } - var bingWords = matrixService.config().bingWords; - var shouldBing = false; - - // case-insensitive name check for user_id OR display_name if they exist - var userRegex = ""; - var myUserId = matrixService.config().user_id; - if (myUserId) { - var localpart = getLocalPartFromUserId(myUserId); - if (localpart) { - localpart = localpart.toLocaleLowerCase(); - userRegex += "\\b" + localpart + "\\b"; - } - } - var myDisplayName = matrixService.config().display_name; - if (myDisplayName) { - myDisplayName = myDisplayName.toLocaleLowerCase(); - if (userRegex.length > 0) { - userRegex += "|"; - } - userRegex += "\\b" + myDisplayName + "\\b"; - } - - var r = new RegExp(userRegex, 'i'); - if (content.search(r) >= 0) { - shouldBing = true; - } - - if ( (myDisplayName && content.toLocaleLowerCase().indexOf(myDisplayName) != -1) || - (myUserId && content.toLocaleLowerCase().indexOf(myUserId) != -1) ) { - shouldBing = true; - } - - // bing word list check - if (bingWords && !shouldBing) { - for (var i=0; i