Skip to content

Commit

Permalink
Rename updatePackageXml() to updatePackage().
Browse files Browse the repository at this point in the history
It will update more files in the future.
  • Loading branch information
yunosh committed Oct 25, 2017
1 parent 3eb12b1 commit 6514ea9
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion lib/Components/Component.php
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ public function getDocumentOrigin();
*
* @return NULL
*/
public function updatePackageXml($action, $options);
public function updatePackage($action, $options);

/**
* Update the component changelog.
Expand Down
2 changes: 1 addition & 1 deletion lib/Components/Component/Base.php
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ public function getDocumentOrigin()
*
* @return NULL
*/
public function updatePackageXml($action, $options)
public function updatePackage($action, $options)
{
throw new Components_Exception(
'Updating the package.xml is not supported!'
Expand Down
4 changes: 2 additions & 2 deletions lib/Components/Component/Source.php
Original file line number Diff line number Diff line change
Expand Up @@ -151,13 +151,13 @@ public function getDocumentOrigin()
}

/**
* Updates the package.xml file for this component.
* Updates the information files for this component.
*
* @param string $action The action to perform. Either "update", "diff",
* or "print".
* @param array $options Options for this operation.
*/
public function updatePackageXml($action, $options)
public function updatePackage($action, $options)
{
if (!file_exists($this->getPackageXmlPath())) {
if (!empty($options['theme'])) {
Expand Down
2 changes: 1 addition & 1 deletion lib/Components/Release/Task/Composer.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public function validate($options)
}
$diff_options = $options;
$diff_options['no_timestamp'] = true;
$diff = $this->getComponent()->updatePackageXml('diff', $diff_options);
$diff = $this->getComponent()->updatePackage('diff', $diff_options);
if (!empty($diff)) {
return array(
"The package.xml file is not up-to-date:\n$diff"
Expand Down
2 changes: 1 addition & 1 deletion lib/Components/Release/Task/Timestamp.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public function validate($options)
}
$diff_options = $options;
$diff_options['no_timestamp'] = true;
$diff = $this->getComponent()->updatePackageXml('diff', $diff_options);
$diff = $this->getComponent()->updatePackage('diff', $diff_options);
if (!empty($diff)) {
return array(
"The package.xml file is not up-to-date:\n$diff"
Expand Down
2 changes: 1 addition & 1 deletion lib/Components/Runner/Update.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public function run()
$this->_output, $options
);
}
$result = $this->_config->getComponent()->updatePackageXml(
$result = $this->_config->getComponent()->updatePackage(
$action, $options
);
if (!empty($options['new_version']) || !empty($options['new_api'])) {
Expand Down

0 comments on commit 6514ea9

Please sign in to comment.