fix: improve error handling for CSV import in upload and ScheduleView
All checks were successful
Deploy tt-tagebuch / deploy (push) Successful in 51s
All checks were successful
Deploy tt-tagebuch / deploy (push) Successful in 51s
This commit is contained in:
@@ -16,7 +16,9 @@ export const uploadCSV = async (req, res) => {
|
||||
});
|
||||
} catch (error) {
|
||||
console.error('Error importing CSV:', error);
|
||||
return res.status(500).json({ error: 'Failed to import CSV data' });
|
||||
return res.status(500).json({
|
||||
error: error.message || 'Failed to import CSV data'
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user