[MOD] Remove decoding code

This requires Cytoplasm #19 however now.
This commit is contained in:
lda 2023-11-30 18:46:37 +01:00
parent 288ab5da54
commit 3c11d666c8
2 changed files with 2 additions and 5 deletions

View file

@ -36,7 +36,7 @@
ROUTE_IMPL(RouteAliasDirectory, path, argp)
{
RouteArgs *args = argp;
char *alias = HttpUrlDecode(ArrayGet(path, 0));
char *alias = ArrayGet(path, 0);
HashMap *request = NULL;
HashMap *response;
@ -124,7 +124,6 @@ ROUTE_IMPL(RouteAliasDirectory, path, argp)
* refactor for it to use a ServerPart */
if (!StrEquals(aliasID.server.hostname, config->serverName))
{
Log(LOG_INFO, "'%s' != '%s'", aliasID.server.hostname, config->serverName);
msg = "Invalid server name.";
HttpResponseStatus(args->context, HTTP_BAD_REQUEST);
response = MatrixErrorCreate(M_INVALID_PARAM, msg);
@ -237,6 +236,5 @@ finish:
UserUnlock(user);
DbUnlock(db, ref);
JsonFree(request);
Free(alias);
return response;
}

View file

@ -35,7 +35,7 @@
ROUTE_IMPL(RouteRoomAliases, path, argp)
{
RouteArgs *args = argp;
char *roomId = HttpUrlDecode(ArrayGet(path, 0));
char *roomId = ArrayGet(path, 0);
char *token;
char *msg;
@ -77,6 +77,5 @@ ROUTE_IMPL(RouteRoomAliases, path, argp)
finish:
DbUnlock(db, ref);
UserUnlock(user);
Free(roomId);
return response;
}