Skip to content

Commit

Permalink
✨ add logging to get_passenger_name for response debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
LokoMoloko98 committed Feb 1, 2025
1 parent 58009a6 commit df6cc81
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions swift-lift-trips-table-ops/swift-lift-trips-table-ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ def get_passenger_name(passenger_id):
response = users_table.query(
KeyConditionExpression=Key('passenger_id').eq(passenger_id)
)
if 'Item' in response:
return response['Item'].get('passenger_name')
print(f"Response: {response}")
return response['Item'].get('passenger_name')
except Exception as e:
print(f"Error getting passenger name: {e}")
return None
Expand Down

0 comments on commit df6cc81

Please sign in to comment.