u
This commit is contained in:
@@ -78,8 +78,11 @@ export default function addChild(provider) {
|
||||
let finalValue = null;
|
||||
|
||||
if (options.attributeValueId != null) {
|
||||
if (typeof options.attributeValueId !== 'number' || !Number.isInteger(options.attributeValueId) || options.attributeValueId <= 0) {
|
||||
throw new Error('Invalid attributeValueId');
|
||||
}
|
||||
const valRes = await runner.query(attrValQueries.GET_BY_ID_AND_COMPANY, {
|
||||
id: Number(options.attributeValueId),
|
||||
id: options.attributeValueId,
|
||||
companyId,
|
||||
});
|
||||
const row = valRes.rows[0];
|
||||
|
||||
Reference in New Issue
Block a user