diff --git a/commerce_authnet.module b/commerce_authnet.module
index 76a3110..7702722 100644
--- a/commerce_authnet.module
+++ b/commerce_authnet.module
@@ -183,7 +183,7 @@ function commerce_authnet_aim_submit_form($payment_method, $pane_values, $checko
  */
 function commerce_authnet_aim_submit_form_validate($payment_method, $pane_form, $pane_values, $order, $form_parents = array()) {
   // If the customer specified a card on file, skip the normal validation.
-  if (module_exists('commerce_cardonfile') && $payment_method['settings']['cim_cardonfile'] && $pane_values['cardonfile'] !== 'new') {
+  if (module_exists('commerce_cardonfile') && isset($payment_method['settings']['cim_cardonfile']) && $pane_values['cardonfile'] !== 'new') {
     return;
   }
 
