Check if order has payment step before checking for @order.payment?

Fixes #2910
point to github's https endpoint to avoid authentication errors.

Fixes #2925
Rename generate_api_key method to ensure_api_key so it doesn't conflict with Admin::UsersController