Missing key on hook variable assignment
This commit is contained in:
@@ -102,7 +102,7 @@ RSpec.describe 'Browser Details Handler', :run_on_browserstack => true do
|
||||
if @hooks['hooked-browsers']['online'].empty?
|
||||
@session = @driver.execute_script("return window.beef.session.get_hook_session_id()")
|
||||
else
|
||||
@session = @hooks['hooked-browsers']['online'][0]
|
||||
@session = @hooks['hooked-browsers']['online'][0]['session']
|
||||
end
|
||||
rescue => exception
|
||||
print_info "Exception: #{exception}"
|
||||
|
||||
@@ -98,11 +98,11 @@ RSpec.describe 'BeEF Debug Command Modules:', :run_on_browserstack => true do
|
||||
|
||||
@hook_request = RestClient.get "#{RESTAPI_HOOKS}?token=#{@token}"
|
||||
@hooks = JSON.parse(@hook_request)
|
||||
|
||||
|
||||
if @hooks['hooked-browsers']['online'].empty?
|
||||
@session = @driver.execute_script("return window.beef.session.get_hook_session_id()")
|
||||
else
|
||||
@session = @hooks['hooked-browsers']['online'][0]
|
||||
@session = @hooks['hooked-browsers']['online'][0]['session']
|
||||
end
|
||||
|
||||
# Grab Command Module IDs as they can differ from machine to machine
|
||||
|
||||
Reference in New Issue
Block a user