You are here

function hackedProjectWebDownloader::get_final_destination in Hacked! 6.2

Same name and namespace in other branches
  1. 7.2 includes/hackedProjectWebDownloader.inc \hackedProjectWebDownloader::get_final_destination()

Returns the final destination of the unpacked project.

File

includes/hacked_project.inc, line 380

Class

hackedProjectWebDownloader
Base class for downloading remote versions of projects.

Code

function get_final_destination() {
  $dir = $this
    ->get_destination();
  $name = $this->project->name;
  $version = $this->project->existing_version;
  $type = $this->project->project_type;

  // More special handling for core:
  if ($type != 'core') {
    $module_dir = $dir . "/{$name}";
  }
  else {
    $module_dir = $dir . '/' . $name . '-' . $version;
  }
  return $module_dir;
}