diff --git a/cmd/mautrix-signal-v2/legacymigrate.sql b/cmd/mautrix-signal-v2/legacymigrate.sql index 6ad95b06..9266e9d3 100644 --- a/cmd/mautrix-signal-v2/legacymigrate.sql +++ b/cmd/mautrix-signal-v2/legacymigrate.sql @@ -21,7 +21,7 @@ FROM user_old WHERE uuid IS NOT NULL AND phone IS NOT NULL; INSERT INTO portal ( bridge_id, id, receiver, mxid, parent_id, parent_receiver, relay_bridge_id, relay_login_id, other_user_id, name, topic, avatar_id, avatar_hash, avatar_mxc, - name_set, avatar_set, topic_set, in_space, + name_set, avatar_set, topic_set, name_is_custom, in_space, room_type, disappear_type, disappear_timer, metadata ) SELECT @@ -50,6 +50,7 @@ SELECT name_set, avatar_set, topic_set, + CASE WHEN LENGTH(chat_id)=44 THEN true ELSE false END, -- name_is_custom false, -- in_space CASE WHEN LENGTH(chat_id)=44 THEN '' ELSE 'dm' END, -- room_type CASE WHEN expiration_time<>0 THEN 'after_read' END, diff --git a/cmd/mautrix-signal-v2/main.go b/cmd/mautrix-signal-v2/main.go index 8d7a1c28..5fe7117f 100644 --- a/cmd/mautrix-signal-v2/main.go +++ b/cmd/mautrix-signal-v2/main.go @@ -51,7 +51,7 @@ func main() { 20, "v0.5.1", "v0.7.0", - m.LegacyMigrateSimple(legacyMigrateRenameTables, legacyMigrateCopyData, 12), + m.LegacyMigrateSimple(legacyMigrateRenameTables, legacyMigrateCopyData, 14), true, ) } diff --git a/go.mod b/go.mod index faa4cee1..7ab4c530 100644 --- a/go.mod +++ b/go.mod @@ -14,12 +14,12 @@ require ( github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e github.com/stretchr/testify v1.9.0 github.com/tidwall/gjson v1.17.1 - go.mau.fi/util v0.6.0 + go.mau.fi/util v0.6.1-0.20240719175439-20a6073e1dd4 golang.org/x/crypto v0.25.0 golang.org/x/exp v0.0.0-20240707233637-46b078467d37 golang.org/x/net v0.27.0 google.golang.org/protobuf v1.34.2 - maunium.net/go/mautrix v0.19.1-0.20240719110719-b881a7d45511 + maunium.net/go/mautrix v0.19.1-0.20240719181800-ea591b0a2e23 nhooyr.io/websocket v1.8.11 ) diff --git a/go.sum b/go.sum index 235a78f3..3c2192b6 100644 --- a/go.sum +++ b/go.sum @@ -67,8 +67,8 @@ github.com/tidwall/sjson v1.2.5 h1:kLy8mja+1c9jlljvWTlSazM7cKDRfJuR/bOJhcY5NcY= github.com/tidwall/sjson v1.2.5/go.mod h1:Fvgq9kS/6ociJEDnK0Fk1cpYF4FIW6ZF7LAe+6jwd28= github.com/yuin/goldmark v1.7.4 h1:BDXOHExt+A7gwPCJgPIIq7ENvceR7we7rOS9TNoLZeg= github.com/yuin/goldmark v1.7.4/go.mod h1:uzxRWxtg69N339t3louHJ7+O03ezfj6PlliRlaOzY1E= -go.mau.fi/util v0.6.0 h1:W6SyB3Bm/GjenQ5iq8Z8WWdN85Gy2xS6L0wmnR7SVjg= -go.mau.fi/util v0.6.0/go.mod h1:ljYdq3sPfpICc3zMU+/mHV/sa4z0nKxc67hSBwnrk8U= +go.mau.fi/util v0.6.1-0.20240719175439-20a6073e1dd4 h1:CYKYs5jwJ0bFJqh6pRoWtC9NIJ0lz0/6i2SC4qEBFaU= +go.mau.fi/util v0.6.1-0.20240719175439-20a6073e1dd4/go.mod h1:ljYdq3sPfpICc3zMU+/mHV/sa4z0nKxc67hSBwnrk8U= go.mau.fi/zeroconfig v0.1.3 h1:As9wYDKmktjmNZW5i1vn8zvJlmGKHeVxHVIBMXsm4kM= go.mau.fi/zeroconfig v0.1.3/go.mod h1:NcSJkf180JT+1IId76PcMuLTNa1CzsFFZ0nBygIQM70= golang.org/x/crypto v0.25.0 h1:ypSNr+bnYL2YhwoMt2zPxHFmbAN1KZs/njMG3hxUp30= @@ -93,7 +93,7 @@ gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= maunium.net/go/mauflag v1.0.0 h1:YiaRc0tEI3toYtJMRIfjP+jklH45uDHtT80nUamyD4M= maunium.net/go/mauflag v1.0.0/go.mod h1:nLivPOpTpHnpzEh8jEdSL9UqO9+/KBJFmNRlwKfkPeA= -maunium.net/go/mautrix v0.19.1-0.20240719110719-b881a7d45511 h1:Qbpe6EdaZn4YzNsJTrowWv34afbc1c8OYij58e7Vl70= -maunium.net/go/mautrix v0.19.1-0.20240719110719-b881a7d45511/go.mod h1:UE+mSQ4sDUuJMbjN0aB9EjQSGgXd48AzMvZ6+QJV1k8= +maunium.net/go/mautrix v0.19.1-0.20240719181800-ea591b0a2e23 h1:F3LI6273WRwlpgkjY/5646XAm0xTnCtyZ5BgIqcfVIg= +maunium.net/go/mautrix v0.19.1-0.20240719181800-ea591b0a2e23/go.mod h1:xP3DCXdPBUe1sPiugLbd5mRh/mJQWfGWyED1S8s9V7c= nhooyr.io/websocket v1.8.11 h1:f/qXNc2/3DpoSZkHt1DQu6rj4zGC8JmkkLkWss0MgN0= nhooyr.io/websocket v1.8.11/go.mod h1:rN9OFWIUwuxg4fR5tELlYC04bXYowCP9GX47ivo2l+c=