[MM-53454] Add export file settings + slash command for public link (#23915)
Co-authored-by: Mattermost Build <build@mattermost.com>
Этот коммит содержится в:
@@ -19,8 +19,7 @@ const jobName = "ExportProcess"
|
||||
|
||||
type AppIface interface {
|
||||
configservice.ConfigService
|
||||
WriteFile(fr io.Reader, path string) (int64, *model.AppError)
|
||||
WriteFileContext(ctx context.Context, fr io.Reader, path string) (int64, *model.AppError)
|
||||
WriteExportFileContext(ctx context.Context, fr io.Reader, path string) (int64, *model.AppError)
|
||||
BulkExport(ctx request.CTX, writer io.Writer, outPath string, job *model.Job, opts model.BulkExportOpts) *model.AppError
|
||||
Log() *mlog.Logger
|
||||
}
|
||||
@@ -45,7 +44,7 @@ func MakeWorker(jobServer *jobs.JobServer, app AppIface) model.Worker {
|
||||
rd, wr := io.Pipe()
|
||||
|
||||
go func() {
|
||||
_, appErr := app.WriteFileContext(context.Background(), rd, filepath.Join(outPath, exportFilename))
|
||||
_, appErr := app.WriteExportFileContext(context.Background(), rd, filepath.Join(outPath, exportFilename))
|
||||
if appErr != nil {
|
||||
// we close the reader here to prevent a deadlock when the bulk exporter tries to
|
||||
// write into the pipe while app.WriteFile has already returned. The error will be
|
||||
|
||||
Ссылка в новой задаче
Block a user