mirror of https://github.com/langgenius/dify.git
fix(trigger): update return type in TriggerSubscriptionBuilderService
- Changed the return type of the method in `TriggerSubscriptionBuilderService` from `SubscriptionBuilder` to `SubscriptionBuilderApiEntity` for improved clarity and alignment with API entity structures. - Updated the return statement to utilize the new method for converting the builder to the API entity.
This commit is contained in:
parent
9249a2af0d
commit
6566824807
|
|
@ -142,7 +142,7 @@ class TriggerSubscriptionBuilderService:
|
|||
user_id: str,
|
||||
provider_id: TriggerProviderID,
|
||||
credential_type: CredentialType,
|
||||
) -> SubscriptionBuilder:
|
||||
) -> SubscriptionBuilderApiEntity:
|
||||
"""
|
||||
Add a new trigger subscription validation.
|
||||
"""
|
||||
|
|
@ -170,7 +170,7 @@ class TriggerSubscriptionBuilderService:
|
|||
redis_client.setex(
|
||||
cache_key, cls.__VALIDATION_REQUEST_CACHE_EXPIRE_MS__, subscription_builder.model_dump_json()
|
||||
)
|
||||
return subscription_builder
|
||||
return cls.builder_to_api_entity(controller=provider_controller, entity=subscription_builder)
|
||||
|
||||
@classmethod
|
||||
def update_trigger_subscription_builder(
|
||||
|
|
|
|||
Loading…
Reference in New Issue