Skip to content

Commit c8e1801

Browse files
fedarsialitskifilak-sap
authored andcommitted
doc: fix typos in the USAGE section and docstrings
Adapted commit of FedorSelitsky <[email protected]> from PR #14 Signed-off-by: Jakub Filak <[email protected]>
1 parent 50f12e8 commit c8e1801

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

USAGE.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ client = pyodata.Client(SERVICE_URL, requests.Session())
1717
```python
1818
# Get employee identified by 1 and print employee first name
1919
employee1 = client.entity_sets.Employees.get_entity(1).execute()
20-
print employee1.FirstName
20+
print(employee1.FirstName)
2121
```
2222

2323
### Get one entity identified by its key value which is not scalar
@@ -33,7 +33,7 @@ print(order.Quantity)
3333
```python
3434

3535
# Print unique identification (Id) and last name of all cemployees
36-
employees = client.entity_sets.Employees.get_entities().select('EmployeeID,LasttName').execute()
36+
employees = client.entity_sets.Employees.get_entities().select('EmployeeID,LastName').execute()
3737
for employee in employees:
3838
print(employee.EmployeeID, employee.LastName)
3939
```

pyodata/v2/service.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ def __init__(self, handler, entity_key, entity_set_proxy):
321321
self._logger.debug('New instance of EntityGetRequest for last segment: %s', self._entity_set_proxy.last_segment)
322322

323323
def nav(self, nav_property):
324-
"""Navigates to given navigation property and returns the EntritySetProxy"""
324+
"""Navigates to given navigation property and returns the EntitySetProxy"""
325325
return self._entity_set_proxy.nav(nav_property, self._entity_key)
326326

327327
def select(self, select):
@@ -761,7 +761,7 @@ def __getattr__(self, attr):
761761
.format(self._entity_type.name, attr, str(ex)))
762762

763763
def nav(self, nav_property):
764-
"""Navigates to given navigation property and returns the EntritySetProxy"""
764+
"""Navigates to given navigation property and returns the EntitySetProxy"""
765765

766766
# for now duplicated with simillar method in entity set proxy class
767767
try:
@@ -971,7 +971,7 @@ def last_segment(self):
971971
return self._parent_last_segment + entity_set_name
972972

973973
def nav(self, nav_property, key):
974-
"""Navigates to given navigation property and returns the EntritySetProxy"""
974+
"""Navigates to given navigation property and returns the EntitySetProxy"""
975975

976976
try:
977977
navigation_property = self._entity_set.entity_type.nav_proprty(nav_property)

0 commit comments

Comments
 (0)