Skip to content

Instantly share code, notes, and snippets.

@bryanyang0528
Created December 4, 2014 14:49
path
def get_entity(self, key_or_path):
if isinstance(key_or_path, Key):
entities = self.get_entities([key_or_path])
else:
key = Key.from_path(*key_or_path)
entities = self.get_entities([key])
if entities:
return entities[0]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment