From 678fc5e41e1233d914cdf2734f6c573ae0425f00 Mon Sep 17 00:00:00 2001 From: yflory Date: Thu, 22 Oct 2020 11:20:18 +0200 Subject: [PATCH] Make contribution URLs configurable --- customize.dist/pages/features.js | 4 ++-- www/common/cryptpad-common.js | 5 ++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/customize.dist/pages/features.js b/customize.dist/pages/features.js index 00308fc29..6403ec36a 100644 --- a/customize.dist/pages/features.js +++ b/customize.dist/pages/features.js @@ -9,8 +9,8 @@ define([ ], function ($, h, Msg, AppConfig, LocalStore, Pages, Config) { var origin = encodeURIComponent(window.location.hostname); var accounts = { - donateURL: 'https://accounts.cryptpad.fr/#/donate?on=' + origin, - upgradeURL: 'https://accounts.cryptpad.fr/#/?on=' + origin, + donateURL: AppConfig.donateURL || "https://opencollective.com/cryptpad/", + upgradeURL: AppConfig.upgradeURL || 'https://accounts.cryptpad.fr/#/?on=' + origin, }; return function () { Msg.features_f_apps_note = AppConfig.availablePadTypes.map(function (app) { diff --git a/www/common/cryptpad-common.js b/www/common/cryptpad-common.js index 85de0b006..696627cbe 100644 --- a/www/common/cryptpad-common.js +++ b/www/common/cryptpad-common.js @@ -44,9 +44,8 @@ define([ var origin = encodeURIComponent(window.location.hostname); var common = window.Cryptpad = { Messages: Messages, - //donateURL: 'https://accounts.cryptpad.fr/#/donate?on=' + origin, - donateURL: "https://opencollective.com/cryptpad/", - upgradeURL: 'https://accounts.cryptpad.fr/#/?on=' + origin, + donateURL: AppConfig.donateURL || "https://opencollective.com/cryptpad/", + upgradeURL: AppConfig.upgradeURL || 'https://accounts.cryptpad.fr/#/?on=' + origin, account: {}, };