mirror of
https://github.com/strapi/strapi.git
synced 2025-09-18 04:47:27 +00:00
fixes from bad merge
This commit is contained in:
parent
6d0251ea2b
commit
2b3206afea
@ -9,7 +9,6 @@ import { pipeline, PassThrough } from 'stream';
|
||||
import { parser } from 'stream-json/jsonl/Parser';
|
||||
import type { IMetadata, ISourceProvider, ProviderType } from '../../types';
|
||||
|
||||
import { createDecryptionCipher } from '../encryption';
|
||||
import { collect } from '../utils';
|
||||
|
||||
type StreamItemArray = Parameters<typeof chain>[0];
|
||||
@ -104,11 +103,11 @@ class LocalFileSourceProvider implements ISourceProvider {
|
||||
}
|
||||
|
||||
#getBackupStream(decompress = true) {
|
||||
const path = this.options.backupFilePath;
|
||||
const path = this.options.file.path;
|
||||
const readStream = fs.createReadStream(path);
|
||||
const streams: StreamItemArray = [readStream];
|
||||
|
||||
if (compression.enabled) {
|
||||
if (this.options.compression.enabled) {
|
||||
streams.push(zip.createGunzip());
|
||||
}
|
||||
|
||||
@ -116,7 +115,6 @@ class LocalFileSourceProvider implements ISourceProvider {
|
||||
}
|
||||
|
||||
#streamJsonlDirectory(directory: string) {
|
||||
const options = this.options;
|
||||
const inStream = this.#getBackupStream();
|
||||
|
||||
const outStream = new PassThrough({ objectMode: true });
|
||||
|
@ -1,8 +1,8 @@
|
||||
import chalk from 'chalk';
|
||||
import { Writable } from 'stream';
|
||||
|
||||
import type { IDestinationProvider, IMetadata, ProviderType } from '../../../types';
|
||||
import { deleteAllRecords, DeleteOptions } from './restore';
|
||||
import type { IConfiguration, IDestinationProvider, IMetadata, ProviderType } from '../../../types';
|
||||
import { deleteAllRecords, DeleteOptions, restoreConfigs } from './restore';
|
||||
import { mapSchemasValues } from '../../utils';
|
||||
|
||||
export const VALID_STRATEGIES = ['restore', 'merge'];
|
||||
|
Loading…
x
Reference in New Issue
Block a user