See if getting the secret_key and storing as an instance variable will help