Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature 725 - Add environment variable to skip printing IP banner #726

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions core/globalData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ const isDevMode = getConvarBool('txAdminDevMode');
const verboseConvar = getConvarBool('txAdminVerbose');
const debugPlayerlistGenerator = getConvarBool('txDebugPlayerlistGenerator');
const debugExternalSource = getConvarString('txDebugExternalSource');
const skipIpBanner = getConvarBool('txSkipIpBanner');


/**
Expand Down Expand Up @@ -214,6 +215,7 @@ export const convars = Object.freeze({
isDevMode,
debugPlayerlistGenerator,
debugExternalSource,
skipIpBanner,
//Convars - zap dependant
isZapHosting,
forceInterface,
Expand Down
6 changes: 4 additions & 2 deletions core/txAdmin.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import path from 'node:path';
import slash from 'slash';

import logger from '@core/extras/console';
import { txEnv } from '@core/globalData';
import { txEnv, convars } from '@core/globalData';

import { printBanner } from '@core/extras/banner';
import setupProfile from '@core/extras/setupProfile';
Expand Down Expand Up @@ -206,7 +206,9 @@ export default class TxAdmin {
}

//Once they all finish loading, the function below will print the banner
printBanner();
if (!convars.skipIpBanner) {
printBanner();
}

//Run Update Checker every 15 minutes
updateChecker();
Expand Down