From 5ab2f6aa9ae409e485d9106e8bff411c30602462 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Fri, 11 Oct 2024 03:45:56 +0300 Subject: vnext: initial database connection --- vnext/server/index.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'vnext/server/index.js') diff --git a/vnext/server/index.js b/vnext/server/index.js index eaf1ae8a..d58fe4c7 100644 --- a/vnext/server/index.js +++ b/vnext/server/index.js @@ -15,6 +15,7 @@ import { instance } from './middleware/mastodon' const PORT = process.env.LISTEN_PORT || 8081 import path from 'path' import { webhook, webhookPath } from './durov' +import { get_count } from './db/users' // initialize the application and create the routes const app = express() @@ -49,6 +50,9 @@ router.use('*', serverRenderer) app.use(router) +get_count().then(count => { + log(`Registered users: ${JSON.stringify(count)}`) +}).catch(log) // start the app app.listen(PORT, (error) => { -- cgit v1.2.3