   getAlias
   addReferralCode
 }          = require './helpers'
+
+{ generateFakeClient } = require "./client"
 
 
 # this is a hack so express won't write the multipart to /tmp

  sitemapName = req.params.sitemapName
  if sitemapName is ".xml"
    sitemapName = "sitemap.xml"
  else 
    sitemapName = "sitemap" + sitemapName
  JSitemap.one "name" : sitemapName, (err, sitemap)->
    if err or not sitemap

app.get "/-/oauth/google/callback",   require "./google_callback"

app.all '/:name/:section?*', (req, res, next)->

  # sample usage for generateFakeClient
  # generateFakeClient req, res, ()-> console.log arguments[1]

  {JName, JGroup} = koding.models
  {name, section} = req.params
  return res.redirect 302, req.url.substring 7  if name in ['koding', 'guests']
