Skip to content

Fix bug: We want to test for existence of the enum value, not whether it's non-zero#11893

Merged
2 commits merged into
masterfrom
truthy_enum
Oct 27, 2016
Merged

Fix bug: We want to test for existence of the enum value, not whether it's non-zero#11893
2 commits merged into
masterfrom
truthy_enum

Conversation

@ghost
Copy link
Copy Markdown

@ghost ghost commented Oct 27, 2016

No description provided.

Comment thread src/compiler/program.ts
if (host.resolveModuleNames) {
resolveModuleNamesWorker = (moduleNames, containingFile) => host.resolveModuleNames(moduleNames, containingFile).map(resolved => {
// An older host may have omitted extension, in which case we should infer it from the file extension of resolvedFileName.
if (!resolved || resolved.extension) {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

resolved.extension was completely backwards before then? That is, it should have been !resolved.extension to even be close to correct?

@ghost ghost merged commit f307948 into master Oct 27, 2016
@ghost ghost deleted the truthy_enum branch October 27, 2016 16:03
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
This pull request was closed.
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