Skip to content

Commit

Permalink
Merge pull request #83 from DenverCoder1/fix-params
Browse files Browse the repository at this point in the history
  • Loading branch information
DenverCoder1 authored Aug 12, 2021
2 parents 29d0c20 + 8aa28cb commit 0d65a25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/services/badgeUrl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ function getBadgeUrl(
req: Request, item: { slug: string, type: string, data: string } | null,
): string {
// build url using request params and query
const params = Object.values(req.params).join('/');
const params = Object.values(req.params).map((p) => encodeURIComponent(p)).join('/');
const queryString = buildQueryStringFromItem(req, item);
return `https://img.shields.io/${params}?${queryString}`;
}
Expand Down

0 comments on commit 0d65a25

Please sign in to comment.