You are here

protected function InPlaceUpdate::buildUrl in Automatic Updates 8

Build a project quasi-patch download URL.

Parameters

string $project_name: The project name.

string $file_name: The file name.

Return value

string The URL endpoint with for an extension.

1 call to InPlaceUpdate::buildUrl()
InPlaceUpdate::getArchive in src/Services/InPlaceUpdate.php
Get an archive with the quasi-patch contents.

File

src/Services/InPlaceUpdate.php, line 534

Class

InPlaceUpdate
Class to apply in-place updates.

Namespace

Drupal\automatic_updates\Services

Code

protected function buildUrl($project_name, $file_name) {
  $uri = $this->configFactory
    ->get('automatic_updates.settings')
    ->get('download_uri');
  return Url::fromUri("{$uri}/{$project_name}/{$file_name}")
    ->toString();
}