Refactor using Property-access Symfony component