We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 26f8408 commit 8534cfaCopy full SHA for 8534cfa
src/commands/public/resource/store.js
@@ -6,7 +6,7 @@ async function removeBalance(userId, amount) {
6
try {
7
const userProfile = await UserProfile.findOne({ userId });
8
if (!userProfile) {
9
- throw new Error("User profile not found.");
+ console.error("User profile not found.");
10
}
11
12
userProfile.balance -= amount;
@@ -23,7 +23,7 @@ async function getUserBalance(userId) {
23
24
25
26
27
28
29
return userProfile.balance;
@@ -88,5 +88,5 @@ module.exports = {
88
);
89
90
91
- },
+ }
92
};
0 commit comments