update a field specified by a variable

Hello
I would like to update the correct field according to the user’s choice.
Today I solve by doing IF …

    if (choice === "1"){
    item.field1 = item.field1 + 1;
    }
    if (choice === "2"){
    item.field2 = item.field2 + 1;
    }
    if (choice === "3"){
    item.field3 = item.field3 + 1;
    }
    etc...
    
    wixData.update("database", item);

To avoid all these IF, is it possible to replace field1 field2 field3… by a variable field + choice ?

thank you

You can do:

item['field' + choice] += 1;
wixData.update("database", item);

Thanks JD