Merge commit 'be90f19'
Conflicts: DependencyInjection/Configuration.php Generator/CaptchaGenerator.php composer.json
This commit is contained in:
@ -98,6 +98,15 @@ class CaptchaGenerator
|
||||
$this->builder->setMaxFrontLines($options['max_front_lines']);
|
||||
$this->builder->setMaxBehindLines($options['max_behind_lines']);
|
||||
|
||||
if ($options['backgroundColor'] != array()) {
|
||||
if (count($options['backgroundColor'])!=3) {
|
||||
throw new \RuntimeException('backgroundColor should be an array of r, g and b');
|
||||
}
|
||||
|
||||
$color = $options['backgroundColor'];
|
||||
$this->builder->setBackgroundColor($color[0], $color[1], $color[2]);
|
||||
}
|
||||
|
||||
$fingerprint = isset($options['fingerprint']) ? $options['fingerprint'] : null;
|
||||
|
||||
$content = $this->builder->build(
|
||||
|
Reference in New Issue
Block a user