Thanks Mahmoud, your answer saved my day. With Angular 19, I got this weird cyclic dependency error when injescting a service that injects MessageService as well. The only way to solve it was to add MessageService as a provider in the app-config.ts file.