code: func hapiProfileView(w http.ResponseWriter, r *http.Request) {
  	if os.Getenv("ABOT_ENV") != "test" {
  		if !isLoggedIn(w, r) {
  			return
  		}
  		if !isValidCSRF(w, r) {
  			return
  		}
  	}
  
  	cookie, err := r.Cookie("id")
  	if err != nil {
  		writeErrorInternal(w, err)
  		return
  	}
  	uid := cookie.Value
  
  	q := `SELECT authorizationid FROM users WHERE id=$1`
  	var authID sql.NullInt64
  	if err = db.Get(&authID, q, uid); err != nil {
  		writeErrorInternal(w, err)
  		return
  	}
  	if !authID.Valid {
  		// We don't have an auth request in the database for this user,
  		// which is fine.
  		goto Response
  	}
  	q = `UPDATE authorizations SET authorizedat=$1 WHERE id=$2`
  	_, err = db.Exec(q, time.Now(), authID)
  	if err != nil {
  		writeErrorInternal(w, err)
  		return
  	}
  Response:
  	w.WriteHeader(http.StatusOK)
  }
docs: // hapiProfileView is used to validate a purchase or disclosure of
  // sensitive information by a plugin. This method of validation has the user
  // view their profile page, meaning that they have to be logged in on their
  // device, ensuring that they either have a valid email/password or a valid
  // session token in their cookies before the plugin will continue. This is a
  // useful security measure because SMS is not a secure means of communication;
  // SMS messages can easily be hijacked or spoofed. Taking the user to an HTTPS
  // site offers the developer a better guarantee that information entered is
  // coming from the correct person.