Conversation
| @@ -1,16 +1,13 @@ | |||
| Write-Information -Message ("Loading {0} ..." -f ($PSScriptRoot | Split-Path -Leaf)) -InformationAction continue | |||
| Write-Information -Message ("Loading {0} ..." -f ($PSCommandPath | Split-Path -LeafBase)) -InformationAction continue | |||
Check warning
Code scanning / PSScriptAnalyzer
Cmdlet 'Write-Information' may be used incorrectly. Please check that all mandatory parameters are supplied. Warning
| [CmdletBinding()] | ||
| param( | ||
| [Parameter(Mandatory,ValueFromPipeline,Position = 0)] | ||
| [string]$Path |
Check warning
Code scanning / PSScriptAnalyzer
Command accepts pipeline input but has not defined a process block. Warning
| $path = $path | Split-Path -Parent | ||
| continue | ||
| } | ||
|
|
Check notice
Code scanning / PSScriptAnalyzer
Line has trailing whitespace Note
| ) | ||
|
|
||
| # If folderName is not empty | ||
| if($FolderName -ne $null){ |
Check warning
Code scanning / PSScriptAnalyzer
$null should be on the left side of equality comparisons. Warning
| return $MODULE_NAME | ||
| } | ||
|
|
||
| function Get-ModuleFolder{ |
Check notice
Code scanning / PSScriptAnalyzer
The cmdlet 'Get-ModuleFolder' does not have a help comment. Note
| $path = $path | Split-Path -Parent | ||
| continue | ||
| } | ||
|
|
Check notice
Code scanning / PSScriptAnalyzer
Line has trailing whitespace Note
| ) | ||
|
|
||
| # If folderName is not empty | ||
| if($FolderName -ne $null){ |
Check warning
Code scanning / PSScriptAnalyzer
$null should be on the left side of equality comparisons. Warning
| return $MODULE_NAME | ||
| } | ||
|
|
||
| function Get-ModuleFolder{ |
Check notice
Code scanning / PSScriptAnalyzer
The cmdlet 'Get-ModuleFolder' does not have a help comment. Note
|
|
||
| $function = "Invoke-$($MODULE_NAME)GetDbRootPath" | ||
| if(-not (Test-Path -Path function:$function)){ | ||
|
|
Check notice
Code scanning / PSScriptAnalyzer
Line has trailing whitespace Note
| } | ||
| Rename-Item -path Function:Reset-MyModuleDatabaseStore -NewName "Reset-$($moduleName)DatabaseStore" | ||
| Export-ModuleMember -Function "Reset-$($moduleName)DatabaseStore" | ||
|
|
Check notice
Code scanning / PSScriptAnalyzer
Line has trailing whitespace Note
Improve the structure and readability of the Sync-IncludeWithModule code by refining function definitions, enhancing error handling, and ensuring consistent formatting. This refactor aims to streamline the module's functionality and maintainability.