mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-04 10:19:35 +02:00
Convert followers/following in raw SQL queries
Prevent weird bug in SQL generation
This commit is contained in:
parent
d493e2d4bf
commit
bae616273d
11 changed files with 338 additions and 145 deletions
|
@ -99,7 +99,7 @@ export {
|
|||
async function listFollowing (req: express.Request, res: express.Response) {
|
||||
const serverActor = await getServerActor()
|
||||
const resultList = await ActorFollowModel.listInstanceFollowingForApi({
|
||||
id: serverActor.id,
|
||||
followerId: serverActor.id,
|
||||
start: req.query.start,
|
||||
count: req.query.count,
|
||||
sort: req.query.sort,
|
||||
|
@ -159,7 +159,7 @@ async function removeFollowing (req: express.Request, res: express.Response) {
|
|||
const follow = res.locals.follow
|
||||
|
||||
await sequelizeTypescript.transaction(async t => {
|
||||
if (follow.state === 'accepted') await sendUndoFollow(follow, t)
|
||||
if (follow.state === 'accepted') sendUndoFollow(follow, t)
|
||||
|
||||
// Disable redundancy on unfollowed instances
|
||||
const server = follow.ActorFollowing.Server
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue