Skip to content

Commit 333ea45

Browse files
committed
v1.5.2
1 parent 65b1158 commit 333ea45

File tree

1 file changed

+19
-19
lines changed

1 file changed

+19
-19
lines changed

app/application/http/controller/compose.go

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -497,25 +497,25 @@ func (self Compose) Download(http *gin.Context) {
497497
}
498498
}
499499

500-
if !function.IsEmptyArray(yamlRow.Setting.Environment) {
501-
envList := make([]string, 0)
502-
for _, item := range yamlRow.Setting.Environment {
503-
envList = append(envList, fmt.Sprintf("%s=%s", item.Name, item.Value))
504-
}
505-
content := strings.Join(envList, "\n")
506-
zipHeader := &zip.FileHeader{
507-
Name: ".dpanel.env",
508-
Method: zip.Deflate,
509-
UncompressedSize64: uint64(len(content)),
510-
Modified: time.Now(),
511-
}
512-
writer, _ := zipWriter.CreateHeader(zipHeader)
513-
_, err := writer.Write([]byte(content))
514-
if err != nil {
515-
self.JsonResponseWithError(http, err, 500)
516-
return
517-
}
518-
}
500+
//if !function.IsEmptyArray(yamlRow.Setting.Environment) {
501+
// envList := make([]string, 0)
502+
// for _, item := range yamlRow.Setting.Environment {
503+
// envList = append(envList, fmt.Sprintf("%s=%s", item.Name, item.Value))
504+
// }
505+
// content := strings.Join(envList, "\n")
506+
// zipHeader := &zip.FileHeader{
507+
// Name: ".dpanel.env",
508+
// Method: zip.Deflate,
509+
// UncompressedSize64: uint64(len(content)),
510+
// Modified: time.Now(),
511+
// }
512+
// writer, _ := zipWriter.CreateHeader(zipHeader)
513+
// _, err := writer.Write([]byte(content))
514+
// if err != nil {
515+
// self.JsonResponseWithError(http, err, 500)
516+
// return
517+
// }
518+
//}
519519
_ = zipWriter.Close()
520520

521521
http.Header("Content-Type", "application/zip")

0 commit comments

Comments
 (0)