removed useless open
This commit is contained in:
@ -266,7 +266,7 @@ class qualysUtils:
|
|||||||
):
|
):
|
||||||
temp_list = []
|
temp_list = []
|
||||||
max_col_count = 0
|
max_col_count = 0
|
||||||
with open(report, 'rb') as csvfile:
|
with open(report, 'rt') as csvfile:
|
||||||
q_report = csv.reader(csvfile, delimiter=',', quotechar='"')
|
q_report = csv.reader(csvfile, delimiter=',', quotechar='"')
|
||||||
for line in q_report:
|
for line in q_report:
|
||||||
if set(line) == set(section):
|
if set(line) == set(section):
|
||||||
@ -345,7 +345,6 @@ class qualysScanReport:
|
|||||||
if file_stream:
|
if file_stream:
|
||||||
self.open_file = file_in.splitlines()
|
self.open_file = file_in.splitlines()
|
||||||
elif file_in:
|
elif file_in:
|
||||||
|
|
||||||
self.open_file = open(file_in, 'rb')
|
self.open_file = open(file_in, 'rb')
|
||||||
|
|
||||||
self.downloaded_file = None
|
self.downloaded_file = None
|
||||||
@ -353,7 +352,6 @@ class qualysScanReport:
|
|||||||
def grab_sections(self, report):
|
def grab_sections(self, report):
|
||||||
all_dataframes = []
|
all_dataframes = []
|
||||||
dict_tracker = {}
|
dict_tracker = {}
|
||||||
with open(report, 'rb') as csvfile:
|
|
||||||
dict_tracker['WEB_SCAN_VULN_BLOCK'] = pd.DataFrame(self.utils.grab_section(report,
|
dict_tracker['WEB_SCAN_VULN_BLOCK'] = pd.DataFrame(self.utils.grab_section(report,
|
||||||
self.WEB_SCAN_VULN_BLOCK,
|
self.WEB_SCAN_VULN_BLOCK,
|
||||||
end=[
|
end=[
|
||||||
|
Reference in New Issue
Block a user