updated to check customer's secure_key