hbons/SparkleShare-Dashboard — pull request #27 by BigValen (2011-11-06 21:05:21+00:00)
Title: Make directs & LinkCodes more 'externalUrl' friendly

Wrap all res.redirect calls in a convenience function that checks for exports.externalUrl, and prepends it as needed. redirectUrl also checks to see was the target URL fully-specified (http/https), and won't touch it if it is.

Also fixes getLinkCode, by checking for externalUrl rather than req.header('host')