mirror of
https://github.com/bitburner-official/bitburner-src.git
synced 2024-11-18 21:53:50 +01:00
fix bug with ls() that prevented including .txt files
This commit is contained in:
parent
ff3f6da2d4
commit
6a3ac7165d
@ -816,6 +816,16 @@ function NetscriptFunctions(workerScript) {
|
||||
}
|
||||
}
|
||||
|
||||
for (var i = 0; i < server.textFiles.length; i++) {
|
||||
if (filter) {
|
||||
if (server.textFiles[i].fn.includes(filter)) {
|
||||
allFiles.push(server.textFiles[i].fn);
|
||||
}
|
||||
} else {
|
||||
allFiles.push(server.textFiles[i].fn);
|
||||
}
|
||||
}
|
||||
|
||||
//Sort the files alphabetically then print each
|
||||
allFiles.sort();
|
||||
return allFiles;
|
||||
|
Loading…
Reference in New Issue
Block a user