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

use UriComponents for URI#from #181413

Merged
merged 1 commit into from May 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/vs/base/common/uri.ts
Expand Up @@ -334,7 +334,7 @@ export class URI implements UriComponents {
* validation and should be used for untrusted uri components retrieved from storage,
* user input, command arguments etc
*/
static from(components: { scheme: string; authority?: string; path?: string; query?: string; fragment?: string }, strict?: boolean): URI {
static from(components: UriComponents, strict?: boolean): URI {
const result = new Uri(
components.scheme,
components.authority,
Expand Down
8 changes: 1 addition & 7 deletions src/vs/monaco.d.ts
Expand Up @@ -181,13 +181,7 @@ declare namespace monaco {
* validation and should be used for untrusted uri components retrieved from storage,
* user input, command arguments etc
*/
static from(components: {
scheme: string;
authority?: string;
path?: string;
query?: string;
fragment?: string;
}, strict?: boolean): Uri;
static from(components: UriComponents, strict?: boolean): Uri;
/**
* Join a Uri path with path fragments and normalizes the resulting path.
*
Expand Down