R
Reactiflux

✅ – _mercury – 21-51 Aug 29

✅ – _mercury – 21-51 Aug 29

M_mercury8/29/2022
why parseInt does not work here
groups.forEach((group) => {
return Object.keys(group).forEach((key) => {
if (key === 'attributes_count' || key === 'templates_count') {
parseInt(group[key]);
}
if (!group[key]) {
delete group[key];
}
});
});
groups.forEach((group) => {
return Object.keys(group).forEach((key) => {
if (key === 'attributes_count' || key === 'templates_count') {
parseInt(group[key]);
}
if (!group[key]) {
delete group[key];
}
});
});
M_mercury8/29/2022
UUUnknown User8/29/2022
3 Messages Not Public
Sign In & Join Server To View
M_mercury8/29/2022
so?
UUUnknown User8/29/2022
Message Not Public
Sign In & Join Server To View
M_mercury8/29/2022
yes the second if works why ?
UUUnknown User8/29/2022
4 Messages Not Public
Sign In & Join Server To View
M_mercury8/29/2022
UUUnknown User8/29/2022
Message Not Public
Sign In & Join Server To View
M_mercury8/29/2022
groups.forEach((group) => {
return Object.keys(group).forEach((key) => {
if (key === 'attributes_count' || key === 'templates_count') {
group[key] = parseInt(group[key]);
}
if (!group[key]) {
delete group[key];
}
});
});
groups.forEach((group) => {
return Object.keys(group).forEach((key) => {
if (key === 'attributes_count' || key === 'templates_count') {
group[key] = parseInt(group[key]);
}
if (!group[key]) {
delete group[key];
}
});
});
attributes_count + trmplates_count disappear
UUUnknown User8/29/2022
Message Not Public
Sign In & Join Server To View
M_mercury8/29/2022
Ok i got that , thx .. but keys disppaear
UUUnknown User8/29/2022
2 Messages Not Public
Sign In & Join Server To View
M_mercury8/29/2022
group[key] = parseInt(group[key]) || 0; same issue
UUUnknown User8/29/2022
Message Not Public
Sign In & Join Server To View
M_mercury8/29/2022
Aha
UUUnknown User8/29/2022
Message Not Public
Sign In & Join Server To View
M_mercury8/29/2022
ok thanx
groups.forEach((group) => {
return Object.keys(group).forEach((key) => {
if (!group[key]) {
delete group[key];
}
if (key === 'attributes_count' || key === 'templates_count') {
group[key] = parseInt(group[key]) || 0;
}
});
});
groups.forEach((group) => {
return Object.keys(group).forEach((key) => {
if (!group[key]) {
delete group[key];
}
if (key === 'attributes_count' || key === 'templates_count') {
group[key] = parseInt(group[key]) || 0;
}
});
});
UUUnknown User8/29/2022
Message Not Public
Sign In & Join Server To View
M_mercury8/29/2022
I raised the delete up and now it works thanx for smashing that
UUUnknown User8/30/2022
2 Messages Not Public
Sign In & Join Server To View

Looking for more? Join the community!

R
Reactiflux

✅ – _mercury – 21-51 Aug 29

Join Server