We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4653eb6 commit f261823Copy full SHA for f261823
1 file changed
JavaScript/server.js
@@ -6,7 +6,7 @@ const http = require('node:http');
6
const cache = new Map();
7
const lib = './lib/';
8
9
-const cacheFile = path => {
+const cacheFile = (path) => {
10
const filePath = lib + path;
11
try {
12
const libPath = require.resolve(filePath);
@@ -22,14 +22,14 @@ const cacheFile = path => {
22
}
23
};
24
25
-const cacheFolder = path => {
+const cacheFolder = (path) => {
26
fs.readdir(path, (err, files) => {
27
if (err) return;
28
files.forEach(cacheFile);
29
});
30
31
32
-const watch = path => {
+const watch = (path) => {
33
fs.watch(path, (event, file) => {
34
cacheFile(file);
35
0 commit comments