                                     resp = JSON.parse response
                                     if resp.length and resp[0]?
                                         userDetails = @parseTwitterUserDetails resp[0]
+                                        res.send '
+                                            <html>
+                                                <script type="text/javascript">
+                                                    window.location.href = "/";
+                                                </script>
+                                                <body></body>
+                                            </html>'
+                                        ###
                                         models.User.getOrCreateUser userDetails, {}, db, (err, user, token) =>
                                             res.clearCookie "oauth_process_key"
                                             res.cookie "userid", user._id.toString()

                                                    </script>
                                                    <body></body>
                                                </html>'
                                                        
                                    else
                                        utils.log response
                                        res.send "Invalid response."                            
                else
                    utils.log "No token"
                    res.send "Could not connect to Twitter."
            else
                next err                
                



class TwitterAuth extends controller.Controller
    
    twitter: (req, res, text) =>
        oa = new OAuth(
	        "https://api.twitter.com/oauth/request_token",
	        "https://api.twitter.com/oauth/access_token",
