]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/initializers/checker.js
Server: make friends urls come from the request instead of the
[github/Chocobozzz/PeerTube.git] / server / initializers / checker.js
index 3831efb8d5eccffe3d75a464e4270181d6bb4917..2a33009b4ed7b65f26529364b24b0c0d0d5bf415 100644 (file)
@@ -17,8 +17,8 @@ function checkConfig () {
   const required = [ 'listen.port',
     'webserver.https', 'webserver.host', 'webserver.port',
     'database.host', 'database.port', 'database.suffix',
-    'storage.certs', 'storage.uploads', 'storage.logs',
-    'network.friends', 'electron.debug' ]
+    'storage.certs', 'storage.uploads', 'storage.logs', 'storage.thumbnails',
+    'electron.debug' ]
   const miss = []
 
   for (const key of required) {
@@ -39,10 +39,10 @@ function clientsExist (callback) {
 }
 
 function usersExist (callback) {
-  User.list(function (err, users) {
+  User.countTotal(function (err, totalUsers) {
     if (err) return callback(err)
 
-    return callback(null, users.length !== 0)
+    return callback(null, totalUsers !== 0)
   })
 }