Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

missed cases in parse.usesCommonJs #980

Open
3cp opened this issue Apr 7, 2018 · 0 comments
Open

missed cases in parse.usesCommonJs #980

3cp opened this issue Apr 7, 2018 · 0 comments

Comments

@3cp
Copy link

3cp commented Apr 7, 2018

Two missed cases.

  1. npm package @aspnet/signalr file /dist/cjs/ILogger.js
"use strict";
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
Object.defineProperty(exports, "__esModule", { value: true });
var LogLevel;
(function (LogLevel) {
    LogLevel[LogLevel["Trace"] = 0] = "Trace";
    LogLevel[LogLevel["Information"] = 1] = "Information";
    LogLevel[LogLevel["Warning"] = 2] = "Warning";
    LogLevel[LogLevel["Error"] = 3] = "Error";
    LogLevel[LogLevel["None"] = 4] = "None";
})(LogLevel = exports.LogLevel || (exports.LogLevel = {}));
//# sourceMappingURL=ILogger.js.map

The existing parser missed (LogLevel = exports.LogLevel || (exports.LogLevel = {})) the assignment expression in right.

This can be fixed by modifying this line:

exp = node.expression || node.init;

To:

exp = node.expression || node.init || node;
  1. npm package @aspnet/signalr file /dist/cjs/IHubProtocol.js, this is essentially an empty file. Don't know how to reasonably identify this is commonjs file.
"use strict";
// Copyright (c) .NET Foundation. All rights reserved.
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=IHubProtocol.js.map
@3cp 3cp changed the title missing catch in usesCommonJs missing catch in parse.usesCommonJs Apr 7, 2018
@3cp 3cp changed the title missing catch in parse.usesCommonJs missed cases in parse.usesCommonJs Apr 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant