mirror of
https://github.com/fosrl/pangolin.git
synced 2025-07-24 04:34:55 +02:00
move max connections from config to db
This commit is contained in:
parent
a0001aaa74
commit
21e9edd201
4 changed files with 6 additions and 5 deletions
|
@ -25,8 +25,8 @@ export const handleNewtPingRequestMessage: MessageHandler = async (context) => {
|
|||
// higher = more desirable
|
||||
|
||||
let weight = 1;
|
||||
const maxConnections = config.getRawConfig().gerbil.max_connections;
|
||||
if (maxConnections !== undefined) {
|
||||
const maxConnections = node.maxConnections;
|
||||
if (maxConnections !== null && maxConnections !== undefined) {
|
||||
const [currentConnections] = await db
|
||||
.select({
|
||||
count: count()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue