 
 # Render a stripe invoice/receipt using pdfkit = http://pdfkit.org/
 stripe_render_invoice = (invoice_id, download, res) ->
+    if not stripe?
+        # stripe not available, configured or initaialized yet
+        res.status(404).send("stripe not available")
+        return
     invoice = undefined
     customer = undefined
     charge = undefined

                done(undefined, {profile:profile})
            passport.use(new PassportStrategy(opts, verify))

            app.get "/auth/#{strategy}", passport.authenticate(strategy)

            app.get "/auth/#{strategy}/return", passport.authenticate(strategy, {failureRedirect: '/auth/local'}), (req, res) ->
                profile = req.user.profile
                passport_login
                    strategy   : strategy

                            <button type="submit" value="Log In"/>Login</button>
                        </form>""")

        router.post '/auth/local', passport.authenticate('local'), (req, res) ->
            console.log("authenticated... ")
            res.json(req.user)

