(input: string)
| 69 | } |
| 70 | |
| 71 | function normalizePathForCompare(input: string): string { |
| 72 | const resolved = path.resolve(input) |
| 73 | const normalized = path.normalize(resolved) |
| 74 | return process.platform === 'win32' ? normalized.toLowerCase() : normalized |
| 75 | } |
| 76 | |
| 77 | function isSubPath(parent: string, child: string): boolean { |
| 78 | const parentPath = normalizePathForCompare(parent) |