Skip to content
This repository was archived by the owner on Jul 19, 2022. It is now read-only.

Update index.js #2

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Update index.js #2

wants to merge 2 commits into from

Conversation

mr-scrpt
Copy link

change sepatator for unix and windows slash

change sepatator for unix and windows slash
src/index.js Outdated
@@ -151,7 +151,7 @@ module.exports = function (config = {}) {
log.all(id, 'looking in aliases')
for (let [aliasName, aliasPath] of Object.entries(alias)) {
log.all(id, 'looking in aliases', aliasName)
if (id.startsWith(aliasName + path.sep)) {
if (id.startsWith(aliasName + '/' || aliasName + '\\')) {
Copy link
Owner

@n1kk n1kk May 20, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe you meant if (id.startsWith(aliasName + '/') || id.startsWith(aliasName + '\\')) { ?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry yes you're right!

corrections in the condition
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants