Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@meteor-it/fs

Package Overview
Dependencies
Maintainers
2
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@meteor-it/fs - npm Package Compare versions

Comparing version 1.2.2 to 1.2.3

6

index.js
import fsNative from 'fs';
import path from 'path';
import { asyncEach } from '@meteor-it/utils';
import constants from 'constants';
/**

@@ -49,3 +48,2 @@ * Returns true if path is a valid data url

to = path.resolve(to);
console.log(from, to);
if ((await isDirectory(from))) {

@@ -61,3 +59,3 @@ const dirStruct = (await walkDirStruct(from)).map(e => e.replace(from, to));

catch (e) {
if (e.code != constants.ENOENT)
if (e.code !== 'ENOENT')
throw e;

@@ -233,2 +231,2 @@ }

//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInhyZXN0L25vZGVfbW9kdWxlcy9AbWV0ZW9yLWl0L2ZzL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sUUFBbUIsTUFBTSxJQUFJLENBQUM7QUFDckMsT0FBTyxJQUFJLE1BQU0sTUFBTSxDQUFDO0FBQ3hCLE9BQU8sRUFBRSxTQUFTLEVBQUUsTUFBTSxrQkFBa0IsQ0FBQztBQUM3QyxPQUFPLFNBQVMsTUFBTSxXQUFXLENBQUM7QUFHbEM7OztHQUdHO0FBQ0gsU0FBUyxTQUFTLENBQUMsSUFBWTtJQUM5QixPQUFPLHNCQUFzQixDQUFDLElBQUksQ0FBQyxJQUFJLENBQUMsTUFBTSxDQUFDLENBQUMsRUFBRSxHQUFHLENBQUMsQ0FBQyxDQUFBO0FBQ3hELENBQUM7QUFNRDs7O0dBR0c7QUFDSCxTQUFTLFlBQVksQ0FBQyxJQUFZO0lBQ2pDLE9BQU87UUFDTixJQUFJLEVBQUUsSUFBSSxDQUFDLEtBQUssQ0FBQyxDQ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ucyA9IHt9KSB7XG5cdHJldHVybiBmc05hdGl2ZS5jcmVhdGVXcml0ZVN0cmVhbShwYXRoLCBvcHRpb25zKTtcbn1cbiJdfQ==
import fsNative, { Stats } from 'fs';
import path from 'path';
import { asyncEach } from '@meteor-it/utils';
import constants from 'constants';

@@ -65,3 +64,2 @@ type FileHandle = fsNative.promises.FileHandle;

to = path.resolve(to);
console.log(from, to);
if ((await isDirectory(from))) {

@@ -75,3 +73,3 @@ const dirStruct = (await walkDirStruct(from)).map(e => e.replace(from, to));

} catch (e) {
if (e.code != constants.ENOENT) throw e;
if (e.code !== 'ENOENT') throw e;
}

@@ -78,0 +76,0 @@ return;

{
"name": "@meteor-it/fs",
"version": "1.2.2",
"version": "1.2.3",
"description": "Wrappers for native fs module",

@@ -20,3 +20,3 @@ "module": "index.mjs",

},
"gitHead": "a05a4d98386bf058e5ebac4dddd068d9381e6e26"
"gitHead": "c3e6337516e5a535b898252f4b48efaa9fd7ae80"
}

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc