Skip to content

Commit

Permalink
fix(installed): Use 'System.Nullable<bool>' for param 'global' (#5088)
Browse files Browse the repository at this point in the history
  • Loading branch information
niheaven committed Aug 6, 2022
1 parent 9b4ee87 commit 5b5daa5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Expand Up @@ -11,6 +11,7 @@
### Bug Fixes

- **core:** Avoid deadlock in `Invoke-ExternalCommand` ([#5064](https://github.com/ScoopInstaller/Scoop/issues/5064))
- **core:** Use 'System.Nullable<bool>' for param 'global' ([#5088](https://github.com/ScoopInstaller/Scoop/issues/5088))
- **install:** Move from cache when `--no-cache` is specified ([#5039](https://github.com/ScoopInstaller/Scoop/issues/5039))
- **scoop-status:** Correct formatting of `Info` output ([#5047](https://github.com/ScoopInstaller/Scoop/issues/5047))

Expand Down
4 changes: 2 additions & 2 deletions lib/core.ps1
Expand Up @@ -225,8 +225,8 @@ function cache_path($app, $version, $url) { "$cachedir\$app#$version#$($url -rep

# apps
function sanitary_path($path) { return [regex]::replace($path, "[/\\?:*<>|]", "") }
function installed($app, $global) {
if (-not $PSBoundParameters.ContainsKey('global')) {
function installed($app, [Nullable[bool]]$global) {
if ($null -eq $global) {
return (installed $app $false) -or (installed $app $true)
}
# Dependencies of the format "bucket/dependency" install in a directory of form
Expand Down

0 comments on commit 5b5daa5

Please sign in to comment.