8000 chore: Fix linter errors (use isinstance instead of type) (#464) · googleapis/python-datastore@8d33038 · GitHub
[go: up one dir, main page]

Skip to content

Commit 8d33038

Browse files
authored
chore: Fix linter errors (use isinstance instead of type) (#464)
1 parent 12099c8 commit 8d33038

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

google/cloud/datastore/client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ def __init__(
334334
else:
335335
api_endpoint = _DATASTORE_BASE_URL
336336
if client_options:
337-
if type(client_options) == dict:
337+
if isinstance(client_options, dict):
338338
client_options = google.api_core.client_options.from_dict(
339339
client_options
340340
)

tests/unit/test_aggregation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -420,7 +420,7 @@ def test__item_to_aggregation_result():
420420
result = _item_to_aggregation_result(None, map_composite_mock)
421421

422422
assert len(result) == 1
423-
assert type(result[0]) == AggregationResult
423+
assert isinstance(result[0], AggregationResult)
424424

425425
assert result[0].alias == "total"
426426
assert result[0].value == map_composit 37E7 e_mock.__getitem__().integer_value

0 commit comments

Comments
 (0)
0