diff --git a/schematics/utils/ast.ts b/schematics/utils/ast.ts index 9b85064b60..c8fba84043 100644 --- a/schematics/utils/ast.ts +++ b/schematics/utils/ast.ts @@ -172,7 +172,7 @@ export function addServiceToModuleOrStandalone( ): void { const source = getSourceFile(tree, filePath); if (standalone) { - importInStandalone(tree, filePath, serviceName, importPath, 'provides'); + importInStandalone(tree, filePath, serviceName, importPath, 'providers'); } else { const changes = _addProviderToModule(source, filePath, serviceName, importPath); applyChanges(tree, filePath, changes);