mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 12:25:15 +08:00
Merge pull request #657 from woocommerce/PCP-687-do-not-call-partner-referrals-si
Cache partner referrals signup links
This commit is contained in:
commit
259f824dac
9 changed files with 165 additions and 22 deletions
|
@ -67,10 +67,11 @@ class Cache {
|
|||
*
|
||||
* @param string $key The key under which the value should be cached.
|
||||
* @param mixed $value The value to cache.
|
||||
* @param int $expiration Time until expiration in seconds.
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function set( string $key, $value ): bool {
|
||||
return (bool) set_transient( $this->prefix . $key, $value );
|
||||
public function set( string $key, $value, int $expiration = 0 ): bool {
|
||||
return (bool) set_transient( $this->prefix . $key, $value, $expiration );
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue