[server]: Update return_all_data to make it easier to test

This commit is contained in:
2025-03-09 23:23:04 +00:00
parent 6721aedce7
commit 475b8c016a

View File

@ -4,10 +4,10 @@ import boto3
from boto3.dynamodb.conditions import Key, Attr
dynamodb = boto3.resource('dynamodb')
table = dynamodb.Table(os.environ['TABLE_NAME'])
def lambda_handler(event, context):
table = dynamodb.Table(os.environ['TABLE_NAME'])
try:
# Check if objectType is present in query string parameters
if 'queryStringParameters' in event and event['queryStringParameters'] and 'objectType' in event[