]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/initializers/migrations/0080-video-channels.ts
Upgrade server packages
[github/Chocobozzz/PeerTube.git] / server / initializers / migrations / 0080-video-channels.ts
index fc55ef3a214d681554a467318a467e0e1819951a..f197215176c14d876b0767e1f7887f4424933f4d 100644 (file)
@@ -34,7 +34,7 @@ async function up (utils: {
   // Create one author per user that does not already exist
   const users = await utils.db.User.findAll()
   for (const user of users) {
-    const author = await utils.db.Author.find({ where: { userId: user.id }})
+    const author = await utils.db.Author.find({ where: { userId: user.id } })
     if (!author) {
       await utils.db.Author.create({
         name: user.username,
@@ -72,7 +72,7 @@ async function up (utils: {
   const rawVideos = await utils.sequelize.query(query, options)
 
   for (const rawVideo of rawVideos) {
-    const videoChannel = await utils.db.VideoChannel.findOne({ where: { authorId: rawVideo.authorId }})
+    const videoChannel = await utils.db.VideoChannel.findOne({ where: { authorId: rawVideo.authorId } })
 
     const video = await utils.db.Video.findById(rawVideo.id)
     video.channelId = videoChannel.id