wvn
wvn
Explore posts from servers
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
Okay im will look at the vue and what i can make. Thanks
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
Ohh thanks
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
If i can ask what is this for?
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
So like for eshop it will be adduser removeuser, reset login and register? And page for showing products?
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
What do you think is the best to learn :kekw: e shop or blog or ?
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
I will try to make an e-shop with vue. And learn somethingm thanks
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
What is the best way to learn?
18 replies
NNuxt
Created by wvn on 1/23/2025 in #❓・help
Where to start
Like literary no
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
Yep founded the issue. The command handler was usining old version of the my code. So like the code didnt changed at all. Now its all working Thanks!
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
await prisma.ukladanieRole.upsert({ where: { username: c.id }, update: { rolesID: roleIds, username: c.user.username }, create: { username: c.user.username, userID: c.id, rolesID: roleIds, }, });
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
Unique constraint failed on the constraint: UkladanieRole_username_key at Vn.handleRequestError (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules@prisma\client\runtime\library.js:121:7339) at Vn.handleAndLogRequestError (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules@prisma\client\runtime\library.js:121:6663) at Vn.request (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules@prisma\client\runtime\library.js:121:6370) at async l (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules@prisma\client\runtime\library.js:130:9617) at async execute (file:///C:/Users/wvn_0/Desktop/GalaxyBOT/bot/dist/events/discord/leave.js:23:5) Emitted 'error' event at: at C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules@sern\handler\dist\handlers\event-utils.js:45:22 at C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\operators\catchError.js:13:51 at OperatorSubscriber._this._error (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\operators\OperatorSubscriber.js:43:21) at Subscriber.error (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\Subscriber.js:60:18) at Subscriber._error (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\Subscriber.js:84:30) at Subscriber.error (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\Subscriber.js:60:18) at Subscriber._error (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\Subscriber.js:84:30) at Subscriber.error (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\Subscriber.js:60:18) at C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\rxjs\dist\cjs\internal\observable\innerFrom.js:123:47 { code: 'P2002', clientVersion: '6.2.1', meta: { modelName: 'UkladanieRole', target: 'UkladanieRole_username_key' } } Node.js v22.12.0
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
Its not like that its my alt and it didnt changed my name
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
So u are telling to select delete and update and create by userid not username?
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
I im not on pc anymore
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
And with the create it create but crash the bot
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
Yes
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
model UkladanieRole {
id Int @id @default(autoincrement())
username String @unique
userID String @unique
rolesID Json
}
model UkladanieRole {
id Int @id @default(autoincrement())
username String @unique
userID String @unique
rolesID Json
}
18 replies
PPrisma
Created by wvn on 1/10/2025 in #help-and-questions
Error saving in database
Invalid `prisma.ukladanieRole.create()` invocation:


Unique constraint failed on the constraint: `UkladanieRole_username_key`
at Vn.handleRequestError (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:121:7339)
at Vn.handleAndLogRequestError (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:121:6663)
at Vn.request (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:121:6370)
at async l (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:130:9617)
at async execute (file:///C:/Users/wvn_0/Desktop/GalaxyBOT/bot/dist/events/discord/index.js:30:7) {
code: 'P2002',
clientVersion: '6.2.1',
meta: { modelName: 'UkladanieRole', target: 'UkladanieRole_username_key' }
}
Saved role IDs for alphaboosts to the database.
Invalid `prisma.ukladanieRole.create()` invocation:


Unique constraint failed on the constraint: `UkladanieRole_username_key`
at Vn.handleRequestError (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:121:7339)
at Vn.handleAndLogRequestError (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:121:6663)
at Vn.request (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:121:6370)
at async l (C:\Users\wvn_0\Desktop\GalaxyBOT\bot\node_modules\@prisma\client\runtime\library.js:130:9617)
at async execute (file:///C:/Users/wvn_0/Desktop/GalaxyBOT/bot/dist/events/discord/index.js:30:7) {
code: 'P2002',
clientVersion: '6.2.1',
meta: { modelName: 'UkladanieRole', target: 'UkladanieRole_username_key' }
}
Saved role IDs for alphaboosts to the database.
if (!c || !c.user) {
console.log("Invalid member or user data.");
return;
}

console.log(`Event triggered: ${c.user.tag} left the server!`);
console.log(`User ID: ${c.id}`);

const roleIds = c.roles.cache
.filter(
(role) => !ignoredRoleIds.includes(role.id) && role.name !== "@everyone"
)
.map((role) => role.id);

if (roleIds.length === 0) {
console.log("No roles found for this user.");
} else {
console.log("Role IDs:", roleIds);
}

await prisma.ukladanieRole.upsert({
where: { username: c.user.username },
update: { rolesID: roleIds },
create: {
username: c.user.username,
userID: c.id,
rolesID: roleIds,
},
});

console.log(`Saved role IDs for ${c.user.tag} to the database.`);
if (!c || !c.user) {
console.log("Invalid member or user data.");
return;
}

console.log(`Event triggered: ${c.user.tag} left the server!`);
console.log(`User ID: ${c.id}`);

const roleIds = c.roles.cache
.filter(
(role) => !ignoredRoleIds.includes(role.id) && role.name !== "@everyone"
)
.map((role) => role.id);

if (roleIds.length === 0) {
console.log("No roles found for this user.");
} else {
console.log("Role IDs:", roleIds);
}

await prisma.ukladanieRole.upsert({
where: { username: c.user.username },
update: { rolesID: roleIds },
create: {
username: c.user.username,
userID: c.id,
rolesID: roleIds,
},
});

console.log(`Saved role IDs for ${c.user.tag} to the database.`);
Only happens when updating user
18 replies