func devLogin(repo *model.Repo) jqeventrouter.HandlerFunc {
	return func(event *jquery.Event, ui *js.Object, params url.Values) bool {
		provider, token := params.Get("provider"), params.Get("token")
		if provider == "" || token == "" {
			displayError("provider and token are both required")
			return true
		}
		go func() {
			if err := repo.Auth(context.TODO(), provider, token); err != nil {
				displayError("dev mode auth failed: " + err.Error())
				return
			}
			fmt.Printf("Dev Mode Auth succeeded!\n")
			ui.Set("toPage", "index.html")
			event.StopImmediatePropagation()
			js.Global.Get("jQuery").Get("mobile").Call("changePage", "index.html")
		}()
		return true
	}
}
// devLogin handles dev logins in debug builds.
devLogin handles dev logins in debug builds.
// devLogin handles dev logins in debug builds .
func devLogin(repo *model.Repo) jqeventrouter.HandlerFunc {
	return func(event *jquery.Event, ui *js.Object, params url.Values) bool {
		provider, token := params.Get("provider"), params.Get("token")
		if provider == "" || token == "" {
			displayError("provider and token are both required")
			return true
		}
		go func() {
			if err := repo.Auth(context.TODO(), provider, token); err != nil {
				displayError("dev mode auth failed: " + err.Error())
				return
			}
			fmt.Printf("Dev Mode Auth succeeded!\n")
			ui.Set("toPage", "index.html")
			event.StopImmediatePropagation()
			js.Global.Get("jQuery").Get("mobile").Call("changePage", "index.html")
		}()
		return true
	}
}
func devLogin ( repo * model . Repo ) jqeventrouter . HandlerFunc { return func ( event * jquery . Event , ui * js . Object , params url . Values ) bool { provider , token := params . Get ( " " ) , params . Get ( " " ) if provider == " " || token == " " { displayError ( " " ) return true } go func ( ) { if err := repo . Auth ( context . TODO ( ) , provider , token ) ; err != nil { displayError ( " " + err . Error ( ) ) return } fmt . Printf ( " \n " ) ui . Set ( " " , " " ) event . StopImmediatePropagation ( ) js . Global . Get ( " " ) . Get ( " " ) . Call ( " " , " " ) } ( ) return true } }
devLogin handles dev logins in debug builds.
devLogin handles dev logins in debug builds .