stephanecollot / DatetimepickerBundle

MIT License
57 stars 58 forks source link

Calling a function refactoring, optimization #23

Closed nursultanturdaliev closed 4 years ago

nursultanturdaliev commented 9 years ago

Following two codes are equal

$method = 'register' . ucfirst("picker") . 'Configuration';
$this->$method($configs["picker"], $container);

And

$this->registerPickerConfiguration($configs["picker"], $container);
Pierstoval commented 8 years ago

:+1: Could also be refactored to simply

$container->setParameter('sc_datetimepicker.form.options', $configs['picker']['configs']);

No need to add useless methods call