for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Chadicus\Marvel\Api\Cache;
/**
* A PSR-16 implementation which does not save or store any data.
*/
abstract class AbstractCache
{
* Verifies the the given cache key is a legal value.
*
* @param mixed $key The cache key to validate.
* @return void
* @throws InvalidArgumentException Thrown if the $key string is not a legal value.
final protected function verifyKey($key)
if (is_string($key) && trim($key) !== '') {
return;
}
throw new InvalidArgumentException('$key must be a valid non-empty string');