Update dependencies & fix misc formatting errors
This commit is contained in:
@@ -45,7 +45,7 @@ export function deepCopy<T>(target: T): T {
|
||||
return copy.map((item: any) => deepCopy<any>(item)) as any
|
||||
}
|
||||
|
||||
if ( typeof target === 'object' && target !== {} ) {
|
||||
if ( typeof target === 'object' ) {
|
||||
const copy = { ...(target as {[key: string]: any }) } as { [key: string]: any }
|
||||
Object.keys(copy).forEach(key => {
|
||||
copy[key] = deepCopy<any>(copy[key])
|
||||
|
||||
@@ -5,6 +5,7 @@ import * as fs from 'fs'
|
||||
import {Readable, Writable} from 'stream'
|
||||
import {Collection} from '../../collection/Collection'
|
||||
import {UniversalPath} from '../path'
|
||||
import {Maybe} from '../types'
|
||||
|
||||
/**
|
||||
* A Filesystem implementation that stores files on remote hosts via SFTP/SSH.
|
||||
@@ -190,7 +191,7 @@ export class SSHFilesystem extends Filesystem {
|
||||
const sftp = await this.getSFTP()
|
||||
const metaPath = this.metadataPath(storePath)
|
||||
await new Promise<void>((res, rej) => {
|
||||
sftp.writeFile(metaPath, JSON.stringify(meta), err => {
|
||||
sftp.writeFile(metaPath, JSON.stringify(meta), (err: Maybe<Error>) => {
|
||||
if ( err ) {
|
||||
rej(err)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user