nimash3eshan / COMBook

Use shorthand property syntax for object literals JS-0240
Anti-pattern
Minor
2 years ago2 years old
Expected property shorthand.
262    db.collection(type).doc(id).set({
263        id: id,
264        title: title,
265        amount: amount266    }).then(() =>{
267        form.reset();
268    }).catch((error) =>{
Expected property shorthand.
261    if ((id==null) | (id ===""))return;
262    db.collection(type).doc(id).set({
263        id: id,
264        title: title,265        amount: amount
266    }).then(() =>{
267        form.reset();
Expected property shorthand.
260function doAdjustment(id, title, amount, form, type){
261    if ((id==null) | (id ===""))return;
262    db.collection(type).doc(id).set({
263        id: id,264        title: title,
265        amount: amount
266    }).then(() =>{