for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Knp\Rad\User\Salt\Generator;
use Knp\Rad\User\Salt\Generator;
class BCryptAwareWrapper implements Generator
{
/**
* @var Generator
*/
private $wrapped;
* @param Generator $wrapped
public function __construct(Generator $wrapped)
$this->wrapped = $wrapped;
}
* {@inheritdoc}
public function generate()
if (function_exists('password_hash')) {
trigger_error(
'BCrypt and the function password_hash are supported by your PHP version. The salt system is deprecated.',
E_USER_DEPRECATED
);
$this->wrapped->generate();