8000 Fix enumerate syntax error. · mwdaub/python-docs-samples@08b4cce · GitHub
[go: up one dir, main page]

Skip to content

Commit 08b4cce

Browse files
committed
Fix enumerate syntax error.
1 parent b640d19 commit 08b4cce

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

dlp/inspect_content.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ def inspect_string(project, content_string, info_types,
6666
regexes = [{
6767
'info_type': {'name': 'CUSTOM_REGEX_{}'.format(i)},
6868
'regex': {'pattern': custom_regex}
69-
} for i in enumerate(custom_regexes)]
69+
} for i, custom_regex in enumerate(custom_regexes)]
7070
custom_info_types = dictionaries + regexes
7171

7272
# Construct the configuration dictionary. Keys which are None may
@@ -154,7 +154,7 @@ def inspect_file(project, filename, info_types, min_likelihood=None,
154154
regexes = [{
155155
'info_type': {'name': 'CUSTOM_REGEX_{}'.format(i)},
156156
'regex': {'pattern': custom_regex}
157-
} for i in enumerate(custom_regexes)]
157+
} for i, custom_regex in enumerate(custom_regexes)]
158158
custom_info_types = dictionaries + regexes
159159

160160
# Construct the configuration dictionary. Keys which are None may
@@ -267,7 +267,7 @@ def inspect_gcs_file(project, bucket, filename, topic_id, subscription_id,
267267
regexes = [{
268268
'info_type': {'name': 'CUSTOM_REGEX_{}'.format(i)},
269269
'regex': {'pattern': custom_regex}
270-
} for i in enumerate(custom_regexes)]
270+
} for i, custom_regex in enumerate(custom_regexes)]
271271
custom_info_types = dictionaries + regexes
272272

273273
# Construct the configuration dictionary. Keys which are None may
@@ -413,7 +413,7 @@ def inspect_datastore(project, datastore_project, kind,
413413
regexes = [{
414414
'info_type': {'name': 'CUSTOM_REGEX_{}'.format(i)},
415415
'regex': {'pattern': custom_regex}
416-
} for i in enumerate(custom_regexes)]
416+
} for i, custom_regex in enumerate(custom_regexes)]
417417
custom_info_types = dictionaries + regexes
418418

419419
# Construct the configuration dictionary. Keys which are None may
@@ -564,7 +564,7 @@ def inspect_bigquery(project, bigquery_project, dataset_id, table_id,
564564
regexes = [{
565565
'info_type': {'name': 'CUSTOM_REGEX_{}'.format(i)},
566566
'regex': {'pattern': custom_regex}
567-
} for i in enumerate(custom_regexes)]
567+
} for i, custom_regex in enumerate(custom_regexes)]
568568
custom_info_types = dictionaries + regexes
569569

570570
# Construct the configuration dictionary. Keys which are None may

0 commit comments

Comments
 (0)
0