Skip to content

Commit

Permalink
Merge pull request s0md3v#156 from 0xflotus/patch-2
Browse files Browse the repository at this point in the history
chore: improved doc strings
  • Loading branch information
s0md3v authored Mar 2, 2022
2 parents 9e7fe27 + 00b64d4 commit 4be2c54
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion arjun/core/error_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def error_handler(response, factors):
if response.status_code == 400:
if factors['same_code'] != 400:
mem.var['kill'] = True
print('%s Server recieved a bad request. Try decreasing the chunk size with -c option' % bad)
print('%s Server received a bad request. Try decreasing the chunk size with -c option' % bad)
return 'kill'
else:
return 'ok'
Expand Down
6 changes: 4 additions & 2 deletions arjun/core/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def extract_headers(headers):
def confirm(array_of_dicts, usable):
"""
extracts the value from single valued dict from an array of dicts
returns a array of dicts
returns an array of dicts
"""
param_groups = []
for dic in array_of_dicts:
Expand Down Expand Up @@ -104,13 +104,15 @@ def diff_map(body_1, body_2):
def random_str(n):
"""
generates a random string of length n
returns a string containing only digits
"""
return ''.join(str(random.choice(range(10))) for i in range(n))


def get_params(include):
"""
loads parameters from JSON/query string
returns parameter dict
"""
params = {}
if include:
Expand Down Expand Up @@ -169,7 +171,7 @@ def extract_js(response):
def parse_headers(string):
"""
parses headers
return dict
returns dict
"""
result = {}
for line in string.split('\n'):
Expand Down

0 comments on commit 4be2c54

Please sign in to comment.