fix: update DocumentSync initialization to pass EspoCRMAPI as first argument
This commit is contained in:
@@ -56,8 +56,10 @@ async def handler(event_data: Dict[str, Any], ctx: FlowContext[Any]) -> None:
|
||||
ctx.logger.info(f"Document ID: {entity_id}")
|
||||
ctx.logger.info("=" * 80)
|
||||
|
||||
# Initialize sync utils
|
||||
sync_utils = DocumentSync(ctx)
|
||||
# Initialize sync utils (EspoCRMAPI must be passed as first arg, not ctx)
|
||||
from services.espocrm import EspoCRMAPI
|
||||
espocrm = EspoCRMAPI(ctx)
|
||||
sync_utils = DocumentSync(espocrm, context=ctx)
|
||||
|
||||
try:
|
||||
# Step 1: Get download info from EspoCRM
|
||||
|
||||
Reference in New Issue
Block a user