mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-11-28 10:30:42 +00:00
Merge branch 'seeddms-5.1.x' into seeddms-6.0.x
This commit is contained in:
commit
dbe16602fc
|
|
@ -318,11 +318,17 @@ $EXT_CONF = '.var_export($EXT_CONF, true).';');
|
||||||
* @param string $version version of extension (x.y.z)
|
* @param string $version version of extension (x.y.z)
|
||||||
* @return string name of temporary file with archive
|
* @return string name of temporary file with archive
|
||||||
*/
|
*/
|
||||||
public function createArchive($extname, $version) { /* {{{ */
|
public function createArchive($extname, $version, $dir = null) { /* {{{ */
|
||||||
if(!is_dir($this->extdir ."/". $extname))
|
if(!is_dir($this->extdir ."/". $extname))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
if ($dir) {
|
||||||
|
if (!is_dir($dir))
|
||||||
|
return false;
|
||||||
|
$tmpfile = $dir."/".$extname."-".$version.".zip";
|
||||||
|
} else {
|
||||||
$tmpfile = $this->cachedir."/".$extname."-".$version.".zip";
|
$tmpfile = $this->cachedir."/".$extname."-".$version.".zip";
|
||||||
|
}
|
||||||
|
|
||||||
if(!SeedDMS_Extension_Mgr::Zip($this->extdir."/".$extname, $tmpfile)) {
|
if(!SeedDMS_Extension_Mgr::Zip($this->extdir."/".$extname, $tmpfile)) {
|
||||||
return false;
|
return false;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user