win_find - Fix deduped files mistaken for directories (#58680)
* win_find - Fix deduped files mistaken for directories * Update win_find.ps1 * Update win_find.py * Update win_find.ps1
This commit is contained in:
parent
8def67939d
commit
99796dfa87
3 changed files with 4 additions and 3 deletions
|
@ -0,0 +1,2 @@
|
|||
bugfixes:
|
||||
- "win_find - Fix deduped files mistaken for directories (https://github.com/ansible/ansible/issues/58511)"
|
|
@ -238,13 +238,12 @@ Function Get-FileStat($file) {
|
|||
}
|
||||
|
||||
$islnk = $false
|
||||
$isdir = $false
|
||||
$isdir = $attributes -contains 'Directory'
|
||||
$isshared = $false
|
||||
|
||||
if ($attributes -contains 'ReparsePoint') {
|
||||
# TODO: Find a way to differenciate between soft and junction links
|
||||
$islnk = $true
|
||||
$isdir = $true
|
||||
|
||||
# Try and get the symlink source, can result in failure if link is broken
|
||||
try {
|
||||
|
|
|
@ -262,7 +262,7 @@ files:
|
|||
sample: true
|
||||
islnk:
|
||||
description: If the path is a symbolic link or junction or not.
|
||||
returned: success, path exists
|
||||
returned: success, path exists or deduped files
|
||||
type: bool
|
||||
sample: true
|
||||
isreadonly:
|
||||
|
|
Loading…
Reference in a new issue