Commit Graph

9 Commits

Author SHA1 Message Date
Simon Ser
a6aa7f0008 Make Network.Nick optional
Make Network.Nick optional, default to the user's username. This
will allow adding a global setting to set the nickname in the
future, just like we have for the real name.

References: https://todo.sr.ht/~emersion/soju/110
2021-11-02 23:33:17 +01:00
Simon Ser
9ec1f1a5b0 Add context args to Database interface
This is a mecanical change, which just lifts up the context.TODO()
calls from inside the DB implementations to the callers.

Future work involves properly wiring up the contexts when it makes
sense.
2021-10-18 19:15:15 +02:00
Hubert Hirtz
350057e60b Set hard timeouts on DB transactions 2021-10-15 22:39:14 +02:00
Simon Ser
28e1ca51e7 db_postgres: remove unnecessary DEFAULT NULL in schema 2021-10-14 10:09:01 +02:00
Simon Ser
d334bb18a2 db_postgres: use tx for all queries in StoreClientDeliveryReceipts 2021-10-13 19:15:50 +02:00
Simon Ser
79dbb20f98 db_postgres: quote table name in StoreClientDeliveryReceipts 2021-10-13 17:38:20 +02:00
Simon Ser
ca9fa9198c db_postgres: fix constraints errors
Stop using ON CONFLICT DO UPDATE.

Closes: https://todo.sr.ht/~emersion/soju/138
2021-10-13 10:12:14 +02:00
Hubert Hirtz
eb41ed4171 db_postgres: handle both constraints on network updates
Closes: https://todo.sr.ht/~emersion/soju/138
2021-10-13 08:53:49 +02:00
Hubert Hirtz
6e06663615 PostgreSQL support 2021-10-11 15:21:04 +02:00