Skip to content

Commit

Permalink
minor change
Browse files Browse the repository at this point in the history
  • Loading branch information
thanhdanh27600 committed Apr 6, 2024
1 parent 452a0e5 commit 6cce3bc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion public/locales/vi/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -127,5 +127,5 @@
"otherCountry": "Khác",
"file": "File",
"uploadFile": "Upload file",
"donateDetail": "Duy trì server 100k/ngày, ai đó gánh chung không 🙏"
"donateDetail": "Duy trì server 50k/ngày, ai đó gánh chung không 🙏"
}
2 changes: 1 addition & 1 deletion src/controllers/forward.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ export const handler = api<Forward>(
const hashKey = getRedisKey(REDIS_KEY.MAP_SHORTEN_BY_HASH, hash);
const shortenedUrlCache = (await redis.hgetall(hashKey)) as any;
if (!isEmpty(shortenedUrlCache)) {
// cache hit
valid = shortenService.verifyToken(shortenedUrlCache, token);
if (!valid) return res.send({ errorCode: HttpStatusCode.UNAUTHORIZED, errorMessage: 'UNAUTHORIZED' });
// cache hit
sendMessageToQueue([{ subject: 'forward', body: data }]);
return successHandler(res, { history: shortenedUrlCache, token: encryptS(shortenedUrlCache.id.toString()) });
}
Expand Down

0 comments on commit 6cce3bc

Please sign in to comment.