Skip to content

Fix the NPM listing#2080

Merged
sswguo merged 1 commit intoCommonjava:2.7.xfrom
sswguo:npm_listing
Jun 16, 2022
Merged

Fix the NPM listing#2080
sswguo merged 1 commit intoCommonjava:2.7.xfrom
sswguo:npm_listing

Conversation

@sswguo
Copy link
Copy Markdown
Contributor

@sswguo sswguo commented Jun 16, 2022

Still fix for MMENG-2719, it should not append package.json to browser requests, that should be just for api/content.

@sswguo sswguo requested review from ligangty and ruhan1 June 16, 2022 03:39
// This is used to let galley ignore the NPMPathStorageCalculator handling,
// which will append package.json to a directory transfer and make listing not applicable.
ThreadContext context = ThreadContext.getContext( true );
context.put( RequestContextHelper.IS_RAW_VIEW, Boolean.TRUE );
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

dup? line 101 also set this.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

line 101 set it to false back. I ref the PromotionManager line 666.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Ok. I see. LGTM.

@sswguo
Copy link
Copy Markdown
Contributor Author

sswguo commented Jun 16, 2022

Okay, I will merge this first for tests. thanks.

@sswguo sswguo merged commit 17b90bd into Commonjava:2.7.x Jun 16, 2022
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

Successfully merging this pull request may close these issues.

2 participants