refactor: Remove hardcoded -SiteUrl parameter from SharePoint functions
This commit is contained in:
parent
a5ba06c2bf
commit
87da4e1185
@ -111,8 +111,7 @@ function List-XlsFiles {
|
||||
}
|
||||
|
||||
function Convert-Files {
|
||||
if (-not (Connect-SharePoint -SiteUrl "https://yoursite.sharepoint.com")) {
|
||||
return
|
||||
if (-not (Connect-SharePoint)) {
|
||||
}
|
||||
|
||||
$excel = New-Object -ComObject Excel.Application
|
||||
@ -141,8 +140,7 @@ function Convert-Files {
|
||||
}
|
||||
|
||||
function Move-Files {
|
||||
if (-not (Connect-SharePoint -SiteUrl "https://yoursite.sharepoint.com")) {
|
||||
return
|
||||
if (-not (Connect-SharePoint)) {
|
||||
}
|
||||
|
||||
$files = Get-Content "$env:TEMP\FileList.json" | ConvertFrom-Json
|
||||
|
||||
Loading…
Reference in New Issue
Block a user