Skip to content

Commit

Permalink
Changing recursive parameter to recurse to align with get-pnpfileinfo…
Browse files Browse the repository at this point in the history
…lder and get-childitem
  • Loading branch information
KoenZomers committed Sep 27, 2023
1 parent f64633b commit de3a02c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions documentation/Get-PnPFolderInFolder.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ List subfolders in a folder

### Folder via url
```powershell
Get-PnPFolderInFolder [-FolderSiteRelativeUrl <String>] [-ItemName <String>] [-ExcludeSystemFolders] [-Includes <String[]>] [-Recursive] [-Verbose] [-Connection <PnPConnection>]
Get-PnPFolderInFolder [-FolderSiteRelativeUrl <String>] [-ItemName <String>] [-ExcludeSystemFolders] [-Includes <String[]>] [-Recurse] [-Verbose] [-Connection <PnPConnection>]
```

### Folder via pipebind
```powershell
Get-PnPFolderInFolder [-Identity <FolderPipeBind>] [-ItemName <String>] [-ExcludeSystemFolders] [-Includes <String[]>] [-Recursive] [-Verbose] [-Connection <PnPConnection>]
Get-PnPFolderInFolder [-Identity <FolderPipeBind>] [-ItemName <String>] [-ExcludeSystemFolders] [-Includes <String[]>] [-Recurse] [-Verbose] [-Connection <PnPConnection>]
```

## DESCRIPTION
Expand Down Expand Up @@ -74,7 +74,7 @@ Returns all folders in the "Shared Documents" folder which is located in the roo

### EXAMPLE 7
```powershell
Get-PnPFolderInFolder -FolderSiteRelativeUrl "SitePages" -Recursive
Get-PnPFolderInFolder -FolderSiteRelativeUrl "SitePages" -Recurse
```

Returns all folders, including those located in any subfolders, in the folder SitePages which is located in the root of the current web
Expand Down Expand Up @@ -165,7 +165,7 @@ Accept pipeline input: False
Accept wildcard characters: False
```
### -Recursive
### -Recurse
A switch parameter to include folders of all subfolders in the specified folder
```yaml
Expand Down
4 changes: 2 additions & 2 deletions src/Commands/Files/GetFolderInFolder.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public class GetFolderInFolder : PnPWebRetrievalsCmdlet<Folder>
public string ItemName = string.Empty;

[Parameter(Mandatory = false)]
public SwitchParameter Recursive;
public SwitchParameter Recurse;

[Parameter(Mandatory = false)]
public SwitchParameter ExcludeSystemFolders;
Expand Down Expand Up @@ -95,7 +95,7 @@ private IEnumerable<Folder> GetContents(string FolderSiteRelativeUrl)

IEnumerable<Folder> folderContent = folders;

if (Recursive && folders.Count() > 0)
if (Recurse && folders.Count() > 0)
{
foreach (var folder in folders)
{
Expand Down

0 comments on commit de3a02c

Please sign in to comment.