- // Prefix the code with a keyed hash (64 hex chars) as an integrity check
- $code = hash_hmac( 'sha256', $code, $secretKey ) . $code;
-
- // Cache the compiled PHP code
- $cache->set( $key, $code );
+ // Prefix the cached code with a keyed hash (64 hex chars) as an integrity check
+ $cache->set( $key, hash_hmac( 'sha256', $code, $secretKey ) . $code );