Skip to content

Commit 1612f3e

Browse files
authored
Update index.js
1 parent 4862680 commit 1612f3e

File tree

1 file changed

+2
-2
lines changed
  • packages/angular-cli/blueprints/directive

1 file changed

+2
-2
lines changed

packages/angular-cli/blueprints/directive/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,8 @@ module.exports = {
8787
const fileName = stringUtils.dasherize(`${options.entity.name}.directive`);
8888
const fullGeneratePath = path.join(this.project.root, this.generatePath);
8989
const moduleDir = path.parse(this.pathToModule).dir;
90-
const relativeDir = path.relative(moduleDir, fullGeneratePath);
91-
const importPath = relativeDir ? `./${relativeDir}/${fileName}` : `./${fileName}`.toLowerCase();
90+
const relativeDir = path.relative(moduleDir, fullGeneratePath).toLowerCase();
91+
const importPath = relativeDir ? `./${relativeDir}/${fileName}` : `./${fileName}`;
9292

9393
if (!options['skip-import']) {
9494
returns.push(

0 commit comments

Comments
 (0)