def callback
      @stripe_user = current_user
      code = params[:code]

      @response = @client.auth_code.get_token(code, {
      :headers => {'Authorization' => "Bearer(::Configuration['stripe_secret_key'])"} #Platform Secret Key
      })
      
      #Save PROJECT owner's new keys
      @stripe_user.stripe_access_token = @response.token
      @stripe_user.stripe_key = @response.params['stripe_publishable_key']
      @stripe_user.stripe_userid = @response.params['stripe_user_id']
      @stripe_user.save

      
      return redirect_to payment_stripe_auth_path(@stripe_user)
    rescue Stripe::AuthenticationError => e
      ::Airbrake.notify({ :error_class => "Stripe #Pay Error", :error_message => "Stripe #Pay Error: #{e.inspect}", :parameters => params}) rescue nil
      Rails.logger.info "-----> #{e.inspect}"
      flash[:error] = e.message
      return redirect_to main_app.user_path(@stripe_user)
    end
def callback
      @stripe_user = current_user
      code = params[:code]

      @response = @client.auth_code.get_token(code, {
      :headers => {'Authorization' => "Bearer(::Configuration['stripe_secret_key'])"} #Platform Secret Key
      })
      
      #Save PROJECT owner's new keys
      @stripe_user.stripe_access_token = @response.token
      @stripe_user.stripe_key = @response.params['stripe_publishable_key']
      @stripe_user.stripe_userid = @response.params['stripe_user_id']
      @stripe_user.save

      
      return redirect_to payment_stripe_auth_path(@stripe_user)
    rescue Stripe::AuthenticationError => e
      ::Airbrake.notify({ :error_class => "Stripe #Pay Error", :error_message => "Stripe #Pay Error: #{e.inspect}", :parameters => params}) rescue nil
      Rails.logger.info "-----> #{e.inspect}"
      flash[:error] = e.message
      return redirect_to main_app.user_path(@stripe_user)
    end
Brings back the authcode from Stripe and makes another call to Stripe to convert to a authtoken