@e-mc/file-manager 0.7.4 → 0.7.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/LICENSE +1 -1
  2. package/index.js +3 -2
  3. package/package.json +10 -10
package/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright 2023 Sukina
1
+ Copyright 2024 An Pham
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
4
 
package/index.js CHANGED
@@ -128,7 +128,8 @@ function resetAssets() {
128
128
  }
129
129
  function recurseDir(output, subDirs, options) {
130
130
  const { ignore, sortBy, recursive } = options;
131
- const items = fs.readdirSync(path.join(...subDirs), { withFileTypes: true })
131
+ const baseDir = path.join(...subDirs);
132
+ const items = fs.readdirSync(baseDir, { withFileTypes: true })
132
133
  .filter(item => item.name)
133
134
  .sort((a, b) => {
134
135
  if (sortBy > 0) {
@@ -143,7 +144,7 @@ function recurseDir(output, subDirs, options) {
143
144
  });
144
145
  for (const item of items) {
145
146
  if (!item.isDirectory()) {
146
- const pathname = path.join(item.path, item.name);
147
+ const pathname = path.join(baseDir, item.name);
147
148
  if (!ignore.includes(pathname)) {
148
149
  output.push(pathname);
149
150
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@e-mc/file-manager",
3
- "version": "0.7.4",
3
+ "version": "0.7.6",
4
4
  "description": "FileManager constructor for E-mc.",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",
@@ -20,15 +20,15 @@
20
20
  "license": "MIT",
21
21
  "homepage": "https://github.com/anpham6/e-mc#readme",
22
22
  "dependencies": {
23
- "@e-mc/cloud": "0.7.4",
24
- "@e-mc/compress": "0.7.4",
25
- "@e-mc/core": "0.7.4",
26
- "@e-mc/document": "0.7.4",
27
- "@e-mc/image": "0.7.4",
28
- "@e-mc/request": "0.7.4",
29
- "@e-mc/task": "0.7.4",
30
- "@e-mc/types": "0.7.4",
31
- "@e-mc/watch": "0.7.4",
23
+ "@e-mc/cloud": "0.7.6",
24
+ "@e-mc/compress": "0.7.6",
25
+ "@e-mc/core": "0.7.6",
26
+ "@e-mc/document": "0.7.6",
27
+ "@e-mc/image": "0.7.6",
28
+ "@e-mc/request": "0.7.6",
29
+ "@e-mc/task": "0.7.6",
30
+ "@e-mc/types": "0.7.6",
31
+ "@e-mc/watch": "0.7.6",
32
32
  "picomatch": "^3.0.1"
33
33
  }
34
34
  }