Socket
Socket
Sign inDemoInstall

ftp-sftp

Package Overview
Dependencies
21
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.0.0 to 1.0.1

index.d.ts

35

index.js

@@ -37,2 +37,10 @@ const FtpClient = require('ftp')

class LocalFileSystem extends FileSystem {
constructor() {
super()
}
static create() {
return new Promise((resolve, reject) => {
return resolve(new LocalFileSystem())
})
}
async list(path) {

@@ -118,5 +126,20 @@ return new Promise((resolve, reject) => {

}
// stats cannot be used with the current FTP library... so this feature will be left out for now
// stat(path) {
// return new Promise((resolve, reject) => {
// fs.stat(path, (err, stats) => {
// if (err) {
// return reject(err)
// }
// resolve(new LocalFileInfo(stats))
// })
// })
// }
}
class LocalFileInfo extends FileInfo {}
class LocalFileInfo extends FileInfo {
isDirectory() {
return this.original.isDirectory()
}
}

@@ -221,2 +244,5 @@ class FtpFileSystem extends FileSystem {

}
isDirectory() {
return this.original.type === 'd'
}
}

@@ -281,3 +307,8 @@

class SftpFileInfo extends FileInfo {
constructor(original) {
super(original)
}
isDirectory() {
return this.original.type === 'd'
}
}

@@ -284,0 +315,0 @@

5

package.json
{
"name": "ftp-sftp",
"version": "1.0.0",
"version": "1.0.1",
"description": "Treat Local, FTP and SFTP file systems the same way.",

@@ -16,3 +16,4 @@ "main": "index.js",

"sftp",
"file-system"
"file-system",
"async"
],

@@ -19,0 +20,0 @@ "author": "Dennis Heckmann",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc