original_string: public static function importError(Model $record, string $handle)
      {
          static::warning('- Error importing '.get_class($record).' '.$handle);
          $errors = $record->getErrors();
          if (!is_array($errors)) {
              static::error('   - An unknown error has occurred');
  
              return;
          }
          foreach ($errors as $subErrors) {
              foreach ($subErrors as $error) {
                  static::error('   - '.$error);
              }
          }
      }
code: public static function importError(Model $record, string $handle)
      {
          static::warning('- Error importing '.get_class($record).' '.$handle);
          $errors = $record->getErrors();
          if (!is_array($errors)) {
              static::error('   - An unknown error has occurred');
  
              return;
          }
          foreach ($errors as $subErrors) {
              foreach ($subErrors as $error) {
                  static::error('   - '.$error);
              }
          }
      }
code_tokens: public static function importError ( Model $ record , string $ handle ) { static :: warning ( '- Error importing ' . get_class ( $ record ) . ' ' . $ handle ) ; $ errors = $ record -> getErrors ( ) ; if ( ! is_array ( $ errors ) ) { static :: error ( '   - An unknown error has occurred' ) ; return ; } foreach ( $ errors as $ subErrors ) { foreach ( $ subErrors as $ error ) { static :: error ( '   - ' . $ error ) ; } } }
docstring: Log an import error.
  
  @param Model  $record
  @param string $handle
docstring_tokens: Log an import error .