From 13284f2a4c844eb7d78e55d075810560f0df267c Mon Sep 17 00:00:00 2001 From: Narek Zakarian Date: Wed, 2 Jul 2025 21:23:09 +0400 Subject: [PATCH] Add caching service for reference transaction status --- modules/ppcp-api-client/services.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/modules/ppcp-api-client/services.php b/modules/ppcp-api-client/services.php index ca6faf11e..fc0736fe3 100644 --- a/modules/ppcp-api-client/services.php +++ b/modules/ppcp-api-client/services.php @@ -275,7 +275,8 @@ return array( ); }, 'api.reference-transaction-status' => static fn ( ContainerInterface $container ): ReferenceTransactionStatus => new ReferenceTransactionStatus( - $container->get( 'api.endpoint.partners' ) + $container->get( 'api.endpoint.partners' ), + $container->get( 'api.reference-transaction-status-cache' ) ), 'api.endpoint.catalog-products' => static function ( ContainerInterface $container ): CatalogProducts { return new CatalogProducts( @@ -871,6 +872,9 @@ return array( 'api.user-id-token-cache' => static function( ContainerInterface $container ): Cache { return new Cache( 'ppcp-id-token-cache' ); }, + 'api.reference-transaction-status-cache' => static function( ContainerInterface $container ): Cache { + return new Cache( 'ppcp-reference-transaction-status-cache' ); + }, 'api.user-id-token' => static function( ContainerInterface $container ): UserIdToken { return new UserIdToken( $container->get( 'api.host' ),