mirror of
https://github.com/codeninjasllc/codecombat.git
synced 2024-11-27 17:45:40 -05:00
18 lines
633 B
CoffeeScript
18 lines
633 B
CoffeeScript
sendwithus = require '../sendwithus'
|
|
utils = require '../lib/utils'
|
|
errors = require '../commons/errors'
|
|
wrap = require 'co-express'
|
|
database = require '../commons/database'
|
|
parse = require '../commons/parse'
|
|
|
|
module.exports =
|
|
sendParentSignupInstructions: wrap (req, res, next) ->
|
|
context =
|
|
email_id: sendwithus.templates.coppa_deny_parent_signup
|
|
recipient:
|
|
address: req.body.parentEmail
|
|
sendwithus.api.send context, (err, result) ->
|
|
if err
|
|
return next(new errors.InternalServerError("Error sending email. Check that it's valid and try again."))
|
|
else
|
|
res.status(200).send()
|