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

Update PackageVersionFileController.ts #716

Closed
wants to merge 5 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions app/port/controller/PackageVersionFileController.ts
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,23 @@
}
return await this.distRepository.getDistStream(file.dist);
}

Check failure on line 173 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Trailing spaces not allowed

Check failure on line 173 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Trailing spaces not allowed

Check failure on line 173 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Trailing spaces not allowed
@HTTPMethod({
path: `/npm/:fullname(${FULLNAME_REG_STRING})/:path(.+)`,
method: HTTPMethodEnum.GET,
})
async rawNpmVer(@Context() ctx: EggContext,
@HTTPParam() fullname: string,
@HTTPParam() path: string,
@HTTPQuery() meta: string) {
let ver = fullname.slice(1).split('@')[1];
if(ver){

Check failure on line 183 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Expected space(s) after "if"

Check failure on line 183 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Missing space before opening brace

Check failure on line 183 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Expected space(s) after "if"

Check failure on line 183 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Missing space before opening brace

Check failure on line 183 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Expected space(s) after "if"

Check failure on line 183 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Missing space before opening brace
fullname = fullname.slice(0,-1-ver.length)

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

A space is required after ','

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Operator '-' must be spaced

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Missing semicolon

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

A space is required after ','

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Operator '-' must be spaced

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Missing semicolon

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

A space is required after ','

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Operator '-' must be spaced

Check failure on line 184 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Missing semicolon
}else{

Check failure on line 185 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Expected space(s) before "else"

Check failure on line 185 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Expected space(s) after "else"

Check failure on line 185 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Expected space(s) before "else"

Check failure on line 185 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Expected space(s) after "else"

Check failure on line 185 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Expected space(s) before "else"

Check failure on line 185 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Expected space(s) after "else"
ver = 'latest'

Check failure on line 186 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (18, ubuntu-latest)

Missing semicolon

Check failure on line 186 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (20, ubuntu-latest)

Missing semicolon

Check failure on line 186 in app/port/controller/PackageVersionFileController.ts

View workflow job for this annotation

GitHub Actions / test-mysql57-fs-nfs (22, ubuntu-latest)

Missing semicolon
}
return await this.raw(ctx, fullname, ver, path, meta);
}

/**
* compatibility with unpkg
Expand Down
Loading