diff options
author | 2020-11-16 00:10:28 +0100 | |
---|---|---|
committer | 2020-11-16 00:10:28 +0100 | |
commit | e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d (patch) | |
tree | 55713f725f77b44ebfec86e4eec3ce33e71458ca /node_modules/@nodelib/fs.stat/out/providers | |
download | website_creator-e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d.tar.gz website_creator-e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d.tar.bz2 website_creator-e06ec920f7a5d784e674c4c4b4e6d1da3dc7391d.zip |
api, login, auth
Diffstat (limited to 'node_modules/@nodelib/fs.stat/out/providers')
4 files changed, 62 insertions, 0 deletions
diff --git a/node_modules/@nodelib/fs.stat/out/providers/async.d.ts b/node_modules/@nodelib/fs.stat/out/providers/async.d.ts new file mode 100644 index 0000000..a9637c5 --- /dev/null +++ b/node_modules/@nodelib/fs.stat/out/providers/async.d.ts @@ -0,0 +1,5 @@ +import Settings from '../settings';
+import { ErrnoException, Stats } from '../types';
+export declare type AsyncCallback = (err: ErrnoException, stats: Stats) => void;
+export declare function read(path: string, settings: Settings, callback: AsyncCallback): void;
+//# sourceMappingURL=async.d.ts.map
\ No newline at end of file diff --git a/node_modules/@nodelib/fs.stat/out/providers/async.js b/node_modules/@nodelib/fs.stat/out/providers/async.js new file mode 100644 index 0000000..ab98c29 --- /dev/null +++ b/node_modules/@nodelib/fs.stat/out/providers/async.js @@ -0,0 +1,31 @@ +"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+function read(path, settings, callback) {
+ settings.fs.lstat(path, (lstatError, lstat) => {
+ if (lstatError !== null) {
+ return callFailureCallback(callback, lstatError);
+ }
+ if (!lstat.isSymbolicLink() || !settings.followSymbolicLink) {
+ return callSuccessCallback(callback, lstat);
+ }
+ settings.fs.stat(path, (statError, stat) => {
+ if (statError !== null) {
+ if (settings.throwErrorOnBrokenSymbolicLink) {
+ return callFailureCallback(callback, statError);
+ }
+ return callSuccessCallback(callback, lstat);
+ }
+ if (settings.markSymbolicLink) {
+ stat.isSymbolicLink = () => true;
+ }
+ callSuccessCallback(callback, stat);
+ });
+ });
+}
+exports.read = read;
+function callFailureCallback(callback, error) {
+ callback(error);
+}
+function callSuccessCallback(callback, result) {
+ callback(null, result);
+}
diff --git a/node_modules/@nodelib/fs.stat/out/providers/sync.d.ts b/node_modules/@nodelib/fs.stat/out/providers/sync.d.ts new file mode 100644 index 0000000..f4c1d78 --- /dev/null +++ b/node_modules/@nodelib/fs.stat/out/providers/sync.d.ts @@ -0,0 +1,4 @@ +import Settings from '../settings';
+import { Stats } from '../types';
+export declare function read(path: string, settings: Settings): Stats;
+//# sourceMappingURL=sync.d.ts.map
\ No newline at end of file diff --git a/node_modules/@nodelib/fs.stat/out/providers/sync.js b/node_modules/@nodelib/fs.stat/out/providers/sync.js new file mode 100644 index 0000000..31dab38 --- /dev/null +++ b/node_modules/@nodelib/fs.stat/out/providers/sync.js @@ -0,0 +1,22 @@ +"use strict";
+Object.defineProperty(exports, "__esModule", { value: true });
+function read(path, settings) {
+ const lstat = settings.fs.lstatSync(path);
+ if (!lstat.isSymbolicLink() || !settings.followSymbolicLink) {
+ return lstat;
+ }
+ try {
+ const stat = settings.fs.statSync(path);
+ if (settings.markSymbolicLink) {
+ stat.isSymbolicLink = () => true;
+ }
+ return stat;
+ }
+ catch (error) {
+ if (!settings.throwErrorOnBrokenSymbolicLink) {
+ return lstat;
+ }
+ throw error;
+ }
+}
+exports.read = read;
|