Skip to content

Commit

Permalink
imp - Getting list of files now have fully-universal pat...
Browse files Browse the repository at this point in the history
...hs

---

When getting list of files in a directory, all of the paths are now neutralized.

---

Type: imp
Breaking: False
Doc Required: False
Part: 1/1
  • Loading branch information
AptiviCEO committed Feb 10, 2024
1 parent 1e86f95 commit b3311de
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion public/Nitrocid/Drivers/Filesystem/BaseFilesystemDriver.cs
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
using Terminaux.Base;
using Nitrocid.Misc.Progress;
using System.Runtime.Serialization;
using Nitrocid.Files;

namespace Nitrocid.Drivers.Filesystem
{
Expand Down Expand Up @@ -858,7 +859,7 @@ public virtual string[] GetFilesystemEntries(string Parent, string Pattern, bool
DebugWriter.WriteDebugStackTrace(ex);
DebugWriter.WriteDebug(DebugLevel.E, "Failed to combine files: {0}", ex.Message);
}
return Entries;
return Entries.Select((path) => FS.NeutralizePath(path)).ToArray();
}

/// <inheritdoc/>
Expand Down
2 changes: 1 addition & 1 deletion public/Nitrocid/Shell/ShellBase/Shells/ShellManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ public static class ShellManager
{ "AdminShell", new AdminShellInfo() },
{ "DebugShell", new DebugShellInfo() }
};
internal readonly static Dictionary<string, BaseShellInfo> availableCustomShells = new();
internal readonly static Dictionary<string, BaseShellInfo> availableCustomShells = [];

/// <summary>
/// List of unified commands
Expand Down

0 comments on commit b3311de

Please sign in to comment.