Don't urlencode event types just yet so older HSes don't 500.

Skip the tests which test for urlencoding, and add a TODO
in matrixService.
This commit is contained in:
Kegan Dougal 2014-11-05 11:28:22 +00:00
parent 9f6d1b10ad
commit 42081b1937
2 changed files with 5 additions and 3 deletions

View file

@ -375,7 +375,9 @@ angular.module('matrixService', [])
sendStateEvent: function(room_id, eventType, content, state_key) {
var path = "/rooms/$room_id/state/"+ encodeURIComponent(eventType);
var path = "/rooms/$room_id/state/"+ eventType;
// TODO: uncomment this when matrix.org is updated, else all state events 500.
// var path = "/rooms/$room_id/state/"+ encodeURIComponent(eventType);
if (state_key !== undefined) {
path += "/" + encodeURIComponent(state_key);
}

View file

@ -231,7 +231,7 @@ describe('MatrixService', function() {
httpBackend.flush();
}));
it('should be able to send generic state events without a state key', inject(
xit('should be able to send generic state events without a state key', inject(
function(matrixService) {
matrixService.setConfig({
access_token: "foobar",
@ -255,7 +255,7 @@ describe('MatrixService', function() {
httpBackend.flush();
}));
it('should be able to send generic state events with a state key', inject(
xit('should be able to send generic state events with a state key', inject(
function(matrixService) {
matrixService.setConfig({
access_token: "foobar",