fix: async/await в addEquipment

This commit is contained in:
Nurs 2026-09-16 12:04:26 +00:00
parent bd9aedbdfe
commit 0602415ba0

View File

@ -367,7 +367,7 @@ function updateCounts() {
}
}
function addEquipment(event) {
async function addEquipment(event) {
event.preventDefault();
const form = event.target;
const formData = new FormData(form);
@ -392,7 +392,7 @@ function addEquipment(event) {
nextCheck: nextCheck,
note: formData.get('note') || ''
};
saveEquipment();
await saveEquipment();
updateAll();
resetForm();
switchTab('all');
@ -415,7 +415,7 @@ function addEquipment(event) {
};
equipment.push(newItem);
saveEquipment();
await saveEquipment();
resetForm();
updateAll();
switchTab('all');