diff --git a/index.js b/index.js index cee6147..1bd7d1e 100644 --- a/index.js +++ b/index.js @@ -63,7 +63,7 @@ const Iofs = { var tmp = list.concat() tmp.forEach(it => { if (this.isdir(it)) { - list = list.concat(this.ls(it)) + list = list.concat(this.ls(it, recursive)) } }) } diff --git a/index.mjs b/index.mjs index 3f1762e..e0434f6 100644 --- a/index.mjs +++ b/index.mjs @@ -63,7 +63,7 @@ export default { var tmp = list.concat() tmp.forEach(it => { if (this.isdir(it)) { - list = list.concat(this.ls(it)) + list = list.concat(this.ls(it, recursive)) } }) } diff --git a/package.json b/package.json index 38cf20a..d541340 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "iofs", - "version": "1.5.0", + "version": "1.5.1", "description": "iofs是一个基于原生fs模块封装的工具, 旨在提供更加方便实用一些常用的API方法(同步), API习惯参考了bash shell。", "main": "index.js", "repository": {