mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-23 14:53:10 -06:00
Review comments
This commit is contained in:
parent
394d2c7c44
commit
c43c56087f
|
|
@ -181,7 +181,7 @@ func (d *Database) RemoveDevices(
|
||||||
func (d *Database) RemoveAllDevices(
|
func (d *Database) RemoveAllDevices(
|
||||||
ctx context.Context, localpart string,
|
ctx context.Context, localpart string,
|
||||||
) (devices []api.Device, err error) {
|
) (devices []api.Device, err error) {
|
||||||
err = sqlutil.WithTransaction(d.db, func(txn *sql.Tx) error {
|
err = d.writer.Do(d.db, nil, func(txn *sql.Tx) error {
|
||||||
devices, err = d.devices.selectDevicesByLocalpart(ctx, txn, localpart)
|
devices, err = d.devices.selectDevicesByLocalpart(ctx, txn, localpart)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
|
|
||||||
|
|
@ -31,7 +31,9 @@ func MustMakeInternalAPI(t *testing.T) (api.UserInternalAPI, accounts.Database)
|
||||||
}
|
}
|
||||||
cfg := &config.UserAPI{
|
cfg := &config.UserAPI{
|
||||||
DeviceDatabase: config.DatabaseOptions{
|
DeviceDatabase: config.DatabaseOptions{
|
||||||
ConnectionString: "file::memory:",
|
ConnectionString: "file::memory:",
|
||||||
|
MaxOpenConnections: 1,
|
||||||
|
MaxIdleConnections: 1,
|
||||||
},
|
},
|
||||||
Matrix: &config.Global{
|
Matrix: &config.Global{
|
||||||
ServerName: serverName,
|
ServerName: serverName,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue