ox_core:v1.5.6
Hi, I'm trying to create group and create an account at the same time with hasAccount: true
Group is ok, but account is not created
await Ox.CreateGroup({
name: "job",
label: "Job",
type: 'job',
grades: [{label: "owner", accountRole: "owner"}],
hasAccount: true,
})
From ox_core below, we generate insertedGrades variable and then this variable is tested : return insertedGrades.affectedRows > 0
But, insertedGrades is an array and not an object so the test is always false and when InsertGroup() return false, group is not setup and account is not created
|
const insertedGrades = (await conn.batch( |
I hope I'm clear
Thanks for work about ox core
ox_core:v1.5.6
Hi, I'm trying to create group and create an account at the same time with
hasAccount: trueGroup is ok, but account is not created
From ox_core below, we generate
insertedGradesvariable and then this variable is tested :return insertedGrades.affectedRows > 0But,
insertedGradesis an array and not an object so the test is always false and whenInsertGroup()return false, group is not setup and account is not createdox_core/server/groups/db.ts
Line 33 in 6eaeb23
I hope I'm clear
Thanks for work about ox core