mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 19:42:24 +02:00
Refactor a little bit controllers
This commit is contained in:
parent
c00100b607
commit
c158a5faab
14 changed files with 625 additions and 504 deletions
|
@ -99,7 +99,7 @@ async function listVideoOwnership (req: express.Request, res: express.Response)
|
|||
return res.json(getFormattedObjects(resultList.data, resultList.total))
|
||||
}
|
||||
|
||||
async function acceptOwnership (req: express.Request, res: express.Response) {
|
||||
function acceptOwnership (req: express.Request, res: express.Response) {
|
||||
return sequelizeTypescript.transaction(async t => {
|
||||
const videoChangeOwnership = res.locals.videoChangeOwnership
|
||||
const channel = res.locals.videoChannel
|
||||
|
@ -126,7 +126,7 @@ async function acceptOwnership (req: express.Request, res: express.Response) {
|
|||
})
|
||||
}
|
||||
|
||||
async function refuseOwnership (req: express.Request, res: express.Response) {
|
||||
function refuseOwnership (req: express.Request, res: express.Response) {
|
||||
return sequelizeTypescript.transaction(async t => {
|
||||
const videoChangeOwnership = res.locals.videoChangeOwnership
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue