Skip to content

Commit f642aa6

Browse files
committed
CLeanup redundant code.
1 parent f7cf750 commit f642aa6

File tree

1 file changed

+2
-3
lines changed
  • modules/post/windows/gather/credentials

1 file changed

+2
-3
lines changed

modules/post/windows/gather/credentials/steam.rb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ def initialize(info={})
4343
end
4444

4545
def run
46-
drive = expand_path('%SystemDrive%')
4746
steamappdata = 'SteamAppData.vdf'
4847
steamconfig = 'config.vdf'
4948
u_rx = /AutoLoginUser\W*\"(.*)\"/
@@ -52,9 +51,9 @@ def run
5251
# the correct program files folder.
5352
# We will just use an x64 only defined env variable to check.
5453
if not expand_path('%ProgramFiles(X86)%').empty?
55-
progs = drive + '\\Program Files (x86)' #x64
54+
progs = expand_path('%ProgramFiles(X86)%') #x64
5655
else
57-
progs = drive + '\\Program Files' #x86
56+
progs = expand_path('%ProgramFiles%') #x86
5857
end
5958
path = progs + '\\Steam\\config\\'
6059

0 commit comments

Comments
 (0)