 
     KD.getSingleton('router').clear @getRouteWithEntryPoint 'Register'
     $('body').removeClass 'recovery'
-    @show =>
-      @animateToForm "register"
-      @$('.flex-wrapper').addClass 'taller'
-      KD.getSingleton('mainController').emit 'InvitationReceived', invite
-
-  hide:(callback)->
+    @animateToForm "register"
+    @$('.flex-wrapper').addClass 'taller'
+    KD.getSingleton('mainController').emit 'InvitationReceived', invite
+
+
+  hide: (callback) ->
 
     @$('.flex-wrapper').removeClass 'expanded'
     @emit "LoginViewHidden"
     @setClass 'hidden'
     callback?()
 
-  show:(callback)->
+
+  show: (callback) ->
 
     @unsetClass 'hidden'
     @emit "LoginViewShown"
-    @hidden = no
     callback?()
 
   # click:(event)->


  viewAppended:->

    @setClass "login-screen login"

    @setTemplate @pistachio()
    @template.update()


  constructor:(options = {}, data)->

    options.cssClass = 'login-screen login'

    super options, data

    @logo = new KDCustomHTMLView
      tagName    : 'a'
      cssClass   : 'koding-logo'
      partial    : '<cite></cite>'
      attributes : href : '/'

    @backToLoginLink = new CustomLinkView
      title       : 'Sign In'
      href        : '/Login'
      click       : ->
        KD.mixpanel 'Login button form in /Login, click'

    @goToRecoverLink = new CustomLinkView
      cssClass    : 'forgot-link'
      title       : 'Forgot your password?'
      testPath    : 'landing-recover-password'
      href        : '/Recover'

    @goToRegisterLink = new CustomLinkView
      title       : 'Sign up'
      href        : '/Register'

    @formHeader = new KDCustomHTMLView
      tagName     : "h4"
      cssClass    : "form-header"
      click       : (event)->
        return  unless $(event.target).is 'a.register'
        KD.mixpanel 'Register button form in /Login, click'

    if KD.utils.oauthEnabled() is yes
      @github          = new KDCustomHTMLView
