Skip to content

Commit

Permalink
chore: remove collection import (#186)
Browse files Browse the repository at this point in the history
Fixes #183
  • Loading branch information
HemangChothani authored Sep 16, 2020
1 parent 3987846 commit 581520c
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions google/cloud/firestore_v1/field_path.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,7 @@

"""Utilities for managing / converting field paths to / from strings."""

try:
from collections import abc as collections_abc
except ImportError: # Python 2.7
import collections as collections_abc
from collections import abc

import re

Expand Down Expand Up @@ -232,7 +229,7 @@ def get_nested_value(field_path, data):

nested_data = data
for index, field_name in enumerate(field_names):
if isinstance(nested_data, collections_abc.Mapping):
if isinstance(nested_data, abc.Mapping):
if field_name in nested_data:
nested_data = nested_data[field_name]
else:
Expand Down

0 comments on commit 581520c

Please sign in to comment.