mirror of
https://github.com/turt2live/matrix-dimension.git
synced 2024-10-01 01:05:53 -04:00
Merge pull request #430 from TheTimeWalker/fix-neb-avatar
Update URLs for neb bots
This commit is contained in:
commit
e2d4ae5e7f
30
src/db/migrations/20210906225500-ChangeAvatarUrlForNeb.ts
Normal file
30
src/db/migrations/20210906225500-ChangeAvatarUrlForNeb.ts
Normal file
@ -0,0 +1,30 @@
|
||||
import { QueryInterface } from "sequelize";
|
||||
|
||||
export default {
|
||||
up: (queryInterface: QueryInterface) => {
|
||||
return Promise.resolve()
|
||||
.then(() =>
|
||||
queryInterface.sequelize.query(
|
||||
"UPDATE dimension_appservice_users SET avatarUrl = REPLACE(avatarUrl, '/img/', '/assets/img/')"
|
||||
)
|
||||
)
|
||||
.then(() =>
|
||||
queryInterface.sequelize.query(
|
||||
"UPDATE dimension_neb_integrations SET avatarUrl = REPLACE(avatarUrl, '/img/', '/assets/img/')"
|
||||
)
|
||||
);
|
||||
},
|
||||
down: (queryInterface: QueryInterface) => {
|
||||
return Promise.resolve()
|
||||
.then(() =>
|
||||
queryInterface.sequelize.query(
|
||||
"UPDATE dimension_appservice_users SET avatarUrl = REPLACE(avatarUrl, '/assets/img/', '/img/')"
|
||||
)
|
||||
)
|
||||
.then(() =>
|
||||
queryInterface.sequelize.query(
|
||||
"UPDATE dimension_neb_integrations SET avatarUrl = REPLACE(avatarUrl, '/assets/img/', '/img/')"
|
||||
)
|
||||
);
|
||||
},
|
||||
};
|
Loading…
Reference in New Issue
Block a user