]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server.ts
typos (#246)
[github/Chocobozzz/PeerTube.git] / server.ts
index a52c47083ed2a4e090eff74b4226c4da62c51fae..a138b63592a8b772516e92226570a1525aed71da 100644 (file)
--- a/server.ts
+++ b/server.ts
@@ -56,6 +56,7 @@ import { installApplication } from './server/initializers'
 import { activitypubHttpJobScheduler, transcodingJobScheduler } from './server/lib/jobs'
 import { VideosPreviewCache } from './server/lib/cache'
 import { apiRouter, clientsRouter, staticRouter, servicesRouter, webfingerRouter, activityPubRouter } from './server/controllers'
+import { BadActorFollowScheduler } from './server/lib/schedulers/bad-actor-follow-scheduler'
 
 // ----------- Command line -----------
 
@@ -81,7 +82,7 @@ if (isTestInstance()) {
 
 // For the logger
 app.use(morgan('combined', {
-  stream: { write: logger.info }
+  stream: { write: logger.info.bind(logger) }
 }))
 // For body requests
 app.use(bodyParser.json({
@@ -168,6 +169,8 @@ function onDatabaseInitDone () {
       // ----------- Make the server listening -----------
       server.listen(port, () => {
         VideosPreviewCache.Instance.init(CONFIG.CACHE.PREVIEWS.SIZE)
+        BadActorFollowScheduler.Instance.enable()
+
         activitypubHttpJobScheduler.activate()
         transcodingJobScheduler.activate()