Add prod urls to verify emails
This commit is contained in:
@ -11,6 +11,7 @@ import { blacklistedUsernames } from '../../server/utils/constants';
|
|||||||
|
|
||||||
const debug = debugFactory('fcc:user:remote');
|
const debug = debugFactory('fcc:user:remote');
|
||||||
const BROWNIEPOINTS_TIMEOUT = [1, 'hour'];
|
const BROWNIEPOINTS_TIMEOUT = [1, 'hour'];
|
||||||
|
const isDev = process.env.NODE_ENV !== 'production';
|
||||||
|
|
||||||
function getAboutProfile({
|
function getAboutProfile({
|
||||||
username,
|
username,
|
||||||
@ -356,6 +357,9 @@ module.exports = function(User) {
|
|||||||
to: email,
|
to: email,
|
||||||
from: 'Team@freecodecamp.com',
|
from: 'Team@freecodecamp.com',
|
||||||
subject: 'Welcome to Free Code Camp!',
|
subject: 'Welcome to Free Code Camp!',
|
||||||
|
protocol: isDev ? null : 'https',
|
||||||
|
host: isDev ? 'localhost' : 'freecodecamp.com',
|
||||||
|
port: isDev ? null : 443,
|
||||||
template: path.join(
|
template: path.join(
|
||||||
__dirname,
|
__dirname,
|
||||||
'..',
|
'..',
|
||||||
|
@ -4,6 +4,7 @@ import { isEmail } from 'validator';
|
|||||||
import path from 'path';
|
import path from 'path';
|
||||||
|
|
||||||
const debug = debugFactory('fcc:user:remote');
|
const debug = debugFactory('fcc:user:remote');
|
||||||
|
const isDev = process.env.NODE_ENV !== 'production';
|
||||||
|
|
||||||
function destroyAllRelated(id, Model) {
|
function destroyAllRelated(id, Model) {
|
||||||
return Observable.fromNodeCallback(
|
return Observable.fromNodeCallback(
|
||||||
@ -70,6 +71,9 @@ module.exports = function(app) {
|
|||||||
to: user.email,
|
to: user.email,
|
||||||
from: 'Team@freecodecamp.com',
|
from: 'Team@freecodecamp.com',
|
||||||
subject: 'Welcome to Free Code Camp!',
|
subject: 'Welcome to Free Code Camp!',
|
||||||
|
protocol: isDev ? null : 'https',
|
||||||
|
host: isDev ? 'localhost' : 'freecodecamp.com',
|
||||||
|
port: isDev ? null : 443,
|
||||||
template: path.join(
|
template: path.join(
|
||||||
__dirname,
|
__dirname,
|
||||||
'..',
|
'..',
|
||||||
|
Reference in New Issue
Block a user