mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2024-12-02 05:19:17 -06:00
Video get SQL optimization
This commit is contained in:
parent
2c897999fe
commit
3e5002477a
@ -127,22 +127,30 @@ enum ScopeNames {
|
||||
attributes: {
|
||||
exclude: [ 'privateKey', 'publicKey' ]
|
||||
},
|
||||
model: () => ActorModel,
|
||||
required: true
|
||||
},
|
||||
{
|
||||
model: () => AccountModel,
|
||||
model: () => ActorModel.unscoped(),
|
||||
required: true,
|
||||
include: [
|
||||
{
|
||||
model: () => ActorModel,
|
||||
attributes: [ 'host' ],
|
||||
model: () => ServerModel.unscoped(),
|
||||
required: false
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
model: () => AccountModel.unscoped(),
|
||||
required: true,
|
||||
include: [
|
||||
{
|
||||
model: () => ActorModel.unscoped(),
|
||||
attributes: {
|
||||
exclude: [ 'privateKey', 'publicKey' ]
|
||||
},
|
||||
required: true,
|
||||
include: [
|
||||
{
|
||||
model: () => ServerModel,
|
||||
attributes: [ 'host' ],
|
||||
model: () => ServerModel.unscoped(),
|
||||
required: false
|
||||
}
|
||||
]
|
||||
|
Loading…
Reference in New Issue
Block a user