26 Sep 2022 |
hexa | --- a/src/datastore/postgres/PgDataStore.ts
+++ b/src/datastore/postgres/PgDataStore.ts
@@ -661,8 +661,9 @@ export class PgDataStore implements DataStore {
public async getRoomsVisibility(roomIds: string[]) {
const map: {[roomId: string]: "public"|"private"} = {};
- const list = `('${roomIds.join("','")}')`;
- const res = await this.pgPool.query(`SELECT room_id, visibility FROM room_visibility WHERE room_id IN ${list}`);
+ const res = await this.pgPool.query("SELECT room_id, visibility FROM room_visibility WHERE room_id IN $1", [
+ roomIds,
+ ]);
for (const row of res.rows) {
map[row.room_id] = row.visibility ? "public" : "private";
}
| 11:28:53 |
@piegames:matrix.org | Good thing that I still haven't updated my bridge from last time, so now I only need to update once 🙈 | 11:28:57 |
hexa | only with postgres, prevents injection apparently | 11:29:01 |
hexa | aren't you on heisenbridge anyhow? | 11:29:14 |
@piegames:matrix.org | I have both, for legacy reasons | 11:29:38 |
hexa | Winter (she/her): and of course they removed the crypto-sdk in this release again 😄 | 11:51:32 |
hexa | they don't mention it, but it's gone | 11:52:18 |
hexa | https://github.com/NixOS/nixpkgs/pull/193022 | 12:00:08 |
Winter (she/her) | In reply to @hexa:lossy.network Winter (she/her): and of course they removed the crypto-sdk in this release again 😄 nooo lmao
is it even worth packaging it then? | 13:32:44 |
Winter (she/her) | (also: "again"? they only added it last release) | 13:33:00 |
hexa | yes, I think so | 13:34:23 |
hexa | 0.35.0 added
0.35.1 removed | 13:34:35 |
hexa | both transitively | 13:34:39 |
Dandellion | In reply to @winterqt:nixos.dev (also: "again"? they only added it last release) again can mean to go back to a previous state | 13:34:59 |
Dandellion | not just repeating | 13:35:04 |
Dandellion | * not just repeating something | 13:35:11 |
hexa | oh, maybe my english is bad 😛 | 13:35:23 |
Dandellion | no it's fine | 13:35:29 |
hexa | because winter is a native speaker I guess 😄 | 13:35:31 |
Winter (she/her) | i'll stop talking because i don't mean to nitpick anyone, sorry >.< | 13:38:13 |
Dandellion | it's apparently obsolete since like 18th century in english (but my native language still has it as well, so no one has ever pointed out the misuse before now) so thanks for pointing it out actually | 13:43:34 |
@linus:schreibt.jetzt | huh, I as a native speaker also understand that use of again | 13:45:40 |
@piegames:matrix.org | So when did the split happen and where did it propagate to? Gotta love etymology | 13:46:31 |
Winter (she/her) | In reply to @linus:schreibt.jetzt huh, I as a native speaker also understand that use of again interesting! to be clear, i read it as they removed it for a second+ time | 13:56:20 |
@linus:schreibt.jetzt | yeah | 13:57:04 |
Dandellion | I don't know anymore, I think its valid with wiktionary's 5th definition (and not obsolete), but I struggle to find examples specifically for a change being undone rather that describing a past state coming back "positively". | 14:00:19 |
Dandellion | if a native speaker understood I'd say it's all good | 14:01:35 |
@linus:schreibt.jetzt | "I added it and then removed it again"? | 14:01:56 |
Dandellion | yes that's how I would have said it | 14:02:13 |
Dandellion | but googling that leads to very few results | 14:02:36 |