Projet

Général

Profil

Révision 280fe687

Ajouté par Assos Assos il y a plus de 8 ans

Weekly update of contrib modules

Voir les différences:

drupal7/sites/all/modules/commerce/commerce.module
470 470
 * Returns the currency code of the site's default currency.
471 471
 */
472 472
function commerce_default_currency() {
473
  return variable_get('commerce_default_currency', 'USD');
473
  $currency_code = variable_get('commerce_default_currency', 'USD');
474
  drupal_alter('commerce_default_currency', $currency_code);
475
  return $currency_code;
474 476
}
475 477

  
476 478
/**
......
950 952
    }
951 953
    else {
952 954
      // Otherwise add the child element with its simple value.
953
      $simplexml_element->addChild("$key", "$value");
955
      $simplexml_element->addChild("$key", htmlspecialchars($value, ENT_QUOTES, 'UTF-8', FALSE));
954 956
    }
955 957
  }
956 958
}
......
987 989
        return (bool) $query
988 990
          ->addTag($entity_info['access arguments']['access tag'])
989 991
          ->addMetaData('account', $account)
992
          ->addMetaData('entity', $entity)
990 993
          ->condition($entity_info['entity keys']['id'], $entity->{$entity_info['entity keys']['id']})
991 994
          ->range(0, 1)
992 995
          ->execute()
......
1239 1242

  
1240 1243
  $context = array(
1241 1244
    'account' => $account,
1245
    'entity' => $query->getMetaData('entity'),
1242 1246
    'entity_type' => $entity_type,
1243 1247
    'base_table' => $base_table
1244 1248
  );

Formats disponibles : Unified diff