Fix jwt-token
This commit is contained in:
@@ -26,9 +26,10 @@ export const EditAlertModal = ({ rule, onClose, onSuccess }) => {
|
||||
const fetchDroneTypes = async () => {
|
||||
try {
|
||||
const response = await api.get('/drone-types');
|
||||
setDroneTypes(response.data);
|
||||
setDroneTypes(response.data.data || []);
|
||||
} catch (error) {
|
||||
console.error('Error fetching drone types:', error);
|
||||
setDroneTypes([]);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user