Skip to content
This repository has been archived by the owner on Apr 19, 2023. It is now read-only.

Commit

Permalink
🐛 Make sure tokenUserId is string
Browse files Browse the repository at this point in the history
  • Loading branch information
AnandChowdhary committed Feb 27, 2020
1 parent df78a1a commit 07d3efd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@staart/manager",
"version": "1.3.20",
"version": "1.3.21",
"main": "index.js",
"repository": "[email protected]:staart/api.git",
"author": "Anand Chowdhary <[email protected]>",
Expand Down Expand Up @@ -125,5 +125,5 @@
"setup"
],
"snyk": true,
"staart-version": "1.3.20"
"staart-version": "1.3.21"
}
2 changes: 1 addition & 1 deletion src/helpers/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ export const organizationUsernameToId = async (id: string) => {

export const userUsernameToId = async (id: string, tokenUserId: string) => {
if (id === "me") {
return tokenUserId;
return String(tokenUserId);
} else if (!id.match(/^-{0,1}\d+$/)) {
return await getUserIdFromUsername(id);
} else {
Expand Down

0 comments on commit 07d3efd

Please sign in to comment.