mirror of
https://gitlab.com/MrFry/mrfrys-node-server
synced 2025-04-01 20:24:18 +02:00
Sorting files in stuff, ignoring auth for acme-challange
This commit is contained in:
@@ -171,7 +171,13 @@ function GetApp () {
|
||||
|
||||
let f = []
|
||||
|
||||
fs.readdirSync(curr).forEach((item) => {
|
||||
let files = fs.readdirSync(curr)
|
||||
files.sort(function (a, b) {
|
||||
return fs.statSync(curr + b).mtime.getTime() -
|
||||
fs.statSync(curr + a).mtime.getTime()
|
||||
})
|
||||
|
||||
files.forEach((item) => {
|
||||
if (item[0] !== '.') {
|
||||
let res = { name: item }
|
||||
let stat = fs.statSync(curr + '/' + item)
|
||||
|
Reference in New Issue
Block a user