Discord wasn't aborting correctly when the key wasn't configured. Livestream test still used an old schema. Configs needed to be updated in commands/templates

main
Zed A. Shaw 2 years ago
parent a9f23581de
commit 82c3ac2aad
  1. 2
      README.md
  2. 31
      commands/templates/client/config.js
  3. 24
      commands/templates/emails/config.js
  4. 14
      commands/templates/secrets/config.json
  5. 4
      lib/queues.js
  6. 2
      queues/discord.js
  7. 1
      tests/ui/livestream.js

@ -17,3 +17,5 @@ If this doesn't work then this might https://github.com/nodejs/node-gyp/blob/mai
```
npm explore npm/node_modules/@npmcli/run-script -g -- npm_config_global=false npm install node-gyp@latest
```
There's also an issue with installing node-pre-gyp where it seems you need to install @mapbox/node-pre-gyp and also node-pre-gyp.

@ -4,28 +4,37 @@
* is allowed to see. Anything else should go in lib/config.js and
* *never* import that file in any client/* files.
*/
export const fake_payments = false;
export const fake_payments = true;
export const webtorrent = {
announce: "https://localhost:5001/tracker",
use_dht: false,
private: true,
tracker: true,
webSeeds: true,
maxConns: 50
private: true
}
export const btcpay_url = 'https://btc.yourpaymentsite.com/modal/btcpay.js';
export const product = {
price: 20,
currency: 'USD',
description: 'Super Product',
id: 1
}
export const btcpay_url = 'https://pay.yoursite.com/modal/btcpay.js';
export const product_id = 1;
// brought over from ljsthw but need to adapt to the new product setting
export const product_id = product.id;
export const base_host = 'http://localhost:5001';
export const support_email = "help@yourcompany.com";
export const paypal_public = {
disabled: true,
client_id: "YOUR PAYPAL PUBLIC KEY",
}
export const stripe_public = {
disabled: false,
client_id: "your_client_key_NOT_secret_key",
client_id: "pk_MhuNltOn2Gq5VBZ9lMNxv4CB3wFOa"
}
export const darkmode_default = "light";
@ -34,6 +43,6 @@ export const register_enabled = true;
export const log_levels = ["debug", "warn", "info", "error", "table", "assert"];
export const twitter_user = "@yourtwitter";
export const twitter_user = "@lzsthw";
export const price = 59;
export const site_name = "localhost:5001";

@ -1,17 +1,17 @@
export const company = {
owner: 'Person A. People',
product: 'Awesome Business',
owner: 'Cool Coder',
product: 'Super Product',
copyright_date: '2021',
name: 'BizTime, LLC',
street: '1234 Weird Street Address',
zip_code: '33333',
city: 'Big City',
state: 'BC',
name: 'Super Company, LLC',
street: 'Address Address',
zip_code: '99999',
city: 'City',
state: 'CC',
country: 'USA',
phone: '1-800-NO-WAY',
mail: 'payments@biztime.com',
website: 'localhost:5001',
credit_line: "CRDT",
forum: "talk.biztime.com",
unsubscribe: "https://localhost:5001/client/#/email/unsubscribe/",
mail: '"Person from PRODUCT" <help@supercool.com>',
website: 'supercool.com',
credit_line: "SUERPCOOL",
forum: "supercool.com",
unsubscribe: "https://supercool.com/client/#/email/unsubscribe/",
}

@ -1,11 +1,19 @@
{
"paypal_private": {
"email": "payments@thesite.com",
"client_id": "",
"secret": "",
"disabled": false
"client_id": "PUBLICCLIENTID",
"secret": "SECRETKEY",
"disabled": true
},
"stripe_private": {
"email": "payments@thesite.com",
"client_id": "pk_YOURPUBLICID",
"secret": "YOURSECRET",
"endpoint_secret": "ENDPOINTSECRET",
"api_version": "2022-08-01",
"disabled": true
},
"btcpay_private": {
"url": "https://yourbtcpayserver.com",
"auth": "your BTC pay auth key",

@ -17,9 +17,9 @@ export const send_welcome = (user) => {
mail.add({user});
}
export const send_receipt = (user, payment_id, course_id) => {
export const send_receipt = (user, payment_id, product_id) => {
const mail = create("mail/receipt");
mail.add({user, payment_id, course_id});
mail.add({user, payment_id, product_id});
}
export const send_reset = (user, ip_address, browser) => {

@ -38,7 +38,7 @@ const load_guild_channel = async (client) => {
}
log.info("Connecting to discord server...");
client.login(discord.token);
await client.login(discord.token);
const [guild, channel] = await load_guild_channel(client);

@ -7,7 +7,6 @@ const fixture = {
"description": "Come hang out and watch me survive the first release of Learn JS the Hard Way.",
"starts_on": "2022-04-15 14:00:00-04",
"is_free": 0,
"course_id": 1,
"state": "pending",
"viewer_count": 206,
"episode": 1

Loading…
Cancel
Save