Moved http response to a function
This commit is contained in:
@@ -326,4 +326,9 @@ def valid_json?(json)
|
||||
return true
|
||||
rescue JSON::ParserError => e
|
||||
return false
|
||||
end
|
||||
|
||||
# Get the HTTP response code
|
||||
def get_http_status(url)
|
||||
Browser.get(url.to_s).code
|
||||
end
|
||||
Reference in New Issue
Block a user