From 9027409ce5f53de323b41ee669cfd1d89323dbe9 Mon Sep 17 00:00:00 2001 From: ansuz Date: Fri, 25 Jun 2021 12:29:13 +0530 Subject: [PATCH] serverside components of instancePurpose flag --- lib/decrees.js | 3 +++ lib/stats.js | 2 ++ 2 files changed, 5 insertions(+) diff --git a/lib/decrees.js b/lib/decrees.js index 960ece1ef..5f599705e 100644 --- a/lib/decrees.js +++ b/lib/decrees.js @@ -173,6 +173,9 @@ commands.SET_SUPPORT_MAILBOX = makeGenericSetter('supportMailbox', function (arg return args_isString(args) && Core.isValidPublicKey(args[0]); }); +// CryptPad_AsyncStore.rpc.send('ADMIN', [ 'ADMIN_DECREE', ['SET_INSTANCE_PURPOSE', ["development"]]], console.log) +commands.SET_INSTANCE_PURPOSE = makeGenericSetter('instancePurpose', args_isString); + // Maintenance: Empty string or an object with a start and end time var isNumber = function (value) { return typeof(value) === "number" && !isNaN(value); diff --git a/lib/stats.js b/lib/stats.js index da820f7b8..2a513da44 100644 --- a/lib/stats.js +++ b/lib/stats.js @@ -14,6 +14,8 @@ Stats.instanceData = function (Env) { adminEmail: Env.adminEmail, consentToContact: Boolean(Env.consentToContact), + + instancePurpose: Env.instancePurpose, // XXX }; /* We reserve the right to choose not to include instances