if (uris.length === 0) {
logger.info('0 followers for %s, no forwarding.', toAccountFollowers.map(a => a.id).join(', '))
- return
+ return undefined
}
logger.debug('Creating forwarding job.', { uris })
const uris = await computeFollowerUris(toAccountFollowers, followersException)
if (uris.length === 0) {
logger.info('0 followers for %s, no broadcasting.', toAccountFollowers.map(a => a.id).join(', '))
- return
+ return undefined
}
logger.debug('Creating broadcast job.', { uris })
loadAndPopulateAccountAndServerAndTags = function (id: number) {
const options = {
+ order: [ [ Video['sequelize'].models.Tag, 'name', 'ASC' ] ],
include: [
{
model: Video['sequelize'].models.VideoChannel,
loadByUUIDAndPopulateAccountAndServerAndTags = function (uuid: string) {
const options = {
+ order: [ [ Video['sequelize'].models.Tag, 'name', 'ASC' ] ],
where: {
uuid
},
expect(video.serverHost).to.equal('localhost:9001')
expect(video.account).to.equal('root')
expect(video.isLocal).to.be.true
- expect(video.tags).to.deep.equal([ 'tag1', 'tag2', 'supertag' ])
+ expect(video.tags).to.deep.equal([ 'supertag', 'tag1', 'tag2' ])
expect(dateIsValid(video.createdAt)).to.be.true
expect(dateIsValid(video.updatedAt)).to.be.true
expect(video.serverHost).to.equal('localhost:9001')
expect(video.account).to.equal('root')
expect(video.isLocal).to.be.true
- expect(video.tags).to.deep.equal([ 'tag1', 'tag2', 'supertag' ])
+ expect(video.tags).to.deep.equal([ 'supertag', 'tag1', 'tag2' ])
expect(dateIsValid(video.createdAt)).to.be.true
expect(dateIsValid(video.updatedAt)).to.be.true