pi-deck 0.1.2 → 0.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/server.js CHANGED
@@ -865,6 +865,9 @@ function isPathAllowed(path, allowedDirectories) {
865
865
  const normalizedPath = canonicalizePath(path);
866
866
  return allowedDirectories.some((allowed) => {
867
867
  const normalizedAllowed = canonicalizePath(allowed);
868
+ if (normalizedAllowed === "/") {
869
+ return true;
870
+ }
868
871
  return normalizedPath === normalizedAllowed || normalizedPath.startsWith(normalizedAllowed + "/");
869
872
  });
870
873
  }