Fix incorrect RegEx pattern
This commit is contained in:
parent
031b07fb54
commit
f91e394e73
1 changed files with 1 additions and 1 deletions
|
@ -372,7 +372,7 @@ class Context {
|
||||||
|
|
||||||
[void] PreventSleepMode() {
|
[void] PreventSleepMode() {
|
||||||
$performanceScheme = "8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c";
|
$performanceScheme = "8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c";
|
||||||
$currentScheme = [regex]::Match((powercfg /GETACTIVESCHEME), "Power Scheme GUID: ([0-9a-f-]) ").Groups[1].Value;
|
$currentScheme = [regex]::Match((powercfg /GETACTIVESCHEME), "Power Scheme GUID: ([0-9a-f-]+) ").Groups[1].Value;
|
||||||
|
|
||||||
if ($currentScheme -ne $performanceScheme) {
|
if ($currentScheme -ne $performanceScheme) {
|
||||||
Write-Information "Disabling Power Save mode";
|
Write-Information "Disabling Power Save mode";
|
||||||
|
|
Loading…
Reference in a new issue