Refactor: remove hard coded values and use $config
Refator: remove logic and use $config