New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

deep-fs

Package Overview
Dependencies
Maintainers
1
Versions
71
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

deep-fs - npm Package Compare versions

Comparing version 1.9.4 to 1.9.5

4

lib.compiled/Exception/Exception.js

@@ -34,3 +34,3 @@ /**

function Exception() {
var _Object$getPrototypeO;
var _ref;

@@ -43,3 +43,3 @@ _classCallCheck(this, Exception);

return _possibleConstructorReturn(this, (_Object$getPrototypeO = Object.getPrototypeOf(Exception)).call.apply(_Object$getPrototypeO, [this].concat(args)));
return _possibleConstructorReturn(this, (_ref = Exception.__proto__ || Object.getPrototypeOf(Exception)).call.apply(_ref, [this].concat(args)));
}

@@ -46,0 +46,0 @@

@@ -33,3 +33,3 @@ /**

return _possibleConstructorReturn(this, Object.getPrototypeOf(UnknownFolderException).call(this, `Unknown folder "${ folderName }". Defined folders are "${ folders.join(', ') }"`));
return _possibleConstructorReturn(this, (UnknownFolderException.__proto__ || Object.getPrototypeOf(UnknownFolderException)).call(this, `Unknown folder "${ folderName }". Defined folders are "${ folders.join(', ') }"`));
}

@@ -36,0 +36,0 @@

@@ -68,3 +68,3 @@ /**

var _this = _possibleConstructorReturn(this, Object.getPrototypeOf(FS).call(this));
var _this = _possibleConstructorReturn(this, (FS.__proto__ || Object.getPrototypeOf(FS)).call(this));

@@ -79,2 +79,3 @@ _this._mountedFolders = {};

_this._sourcePath = null;
_this._registry = null;

@@ -118,2 +119,8 @@ return _this;

break;
case FS.PUBLIC:
let publicBucketObj = bucketsConfig[folder];
this._buckets[folder] = `${ publicBucketObj.name }/${ kernel.microservice().identifier }`;
this._sourcePath = publicBucketObj.sourcePath;
break;
default:

@@ -162,3 +169,9 @@ this._buckets[folder] = `${ bucketsConfig[folder].name }/${ kernel.microservice().identifier }`;

this._mountedFolders[realName || name] = new SimulatedS3FS(rootFolder).relativeFsExtended;
let simulatedS3FS = new SimulatedS3FS(rootFolder); // relativeFsExtended
if (name === FS.PUBLIC && this._sourcePath) {
simulatedS3FS.addReadonlyDirectory(this._sourcePath);
}
this._mountedFolders[realName || name] = simulatedS3FS.relativeFsExtended;
} else if (name === FS.SHARED) {

@@ -165,0 +178,0 @@ let s3Fs = this._mountedFolders[name];

@@ -68,2 +68,41 @@ /**

_createClass(S3FSRelativeFSExtender, [{
key: 'addReadonlyDirectory',
/**
* @param {String} dir
* @returns {S3FSRelativeFSExtender}
*/
value: function addReadonlyDirectory(dir) {
S3FSRelativeFSExtender.READ_METHODS.forEach(method => {
let originalMethod = this._relativeFsObject[method];
this._relativeFsObject[method] = function () {
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
let originalPath = args.shift();
let originalCb = args.pop();
originalMethod.apply(undefined, [originalPath].concat(args, [(error, data) => {
if (error && error.code === 'ENOENT') {
let absPath = _path2.default.join(dir, originalPath);
return _fs2.default[method].apply(_fs2.default, [absPath].concat(args, [originalCb]));
}
originalCb(error, data);
}]));
};
});
return this;
}
/**
* @returns {String[]}
*/
}, {
key: 'relativeFs',

@@ -414,2 +453,7 @@ get: function get() {

}
}, {
key: 'READ_METHODS',
get: function get() {
return ['readFile'];
}
}]);

@@ -416,0 +460,0 @@

{
"name": "deep-fs",
"version": "1.9.4",
"version": "1.9.5",
"description": "DEEP File System Library",

@@ -5,0 +5,0 @@ "keywords": [

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