mirror of
https://github.com/pacnpal/thrilltrack-explorer.git
synced 2025-12-24 09:51:13 -05:00
Fix feature path catch blocks
This commit is contained in:
@@ -27,7 +27,7 @@ export function useCountries() {
|
||||
value: country.toLowerCase().replace(/\s+/g, '_')
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching countries:', error);
|
||||
setCountries([]);
|
||||
} finally {
|
||||
@@ -72,7 +72,7 @@ export function useStatesProvinces(country?: string) {
|
||||
value: state.toLowerCase().replace(/\s+/g, '_')
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching states/provinces:', error);
|
||||
setStatesProvinces([]);
|
||||
} finally {
|
||||
@@ -108,7 +108,7 @@ export function useManufacturers() {
|
||||
value: company.id
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching manufacturers:', error);
|
||||
setManufacturers([]);
|
||||
} finally {
|
||||
@@ -149,7 +149,7 @@ export function useRideModels(manufacturerId?: string) {
|
||||
value: model.id
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching ride models:', error);
|
||||
setRideModels([]);
|
||||
} finally {
|
||||
@@ -188,7 +188,7 @@ export function useCompanyHeadquarters() {
|
||||
value: hq.toLowerCase().replace(/\s+/g, '_')
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching headquarters:', error);
|
||||
setHeadquarters([]);
|
||||
} finally {
|
||||
@@ -224,7 +224,7 @@ export function useOperators() {
|
||||
value: company.id
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching operators:', error);
|
||||
setOperators([]);
|
||||
} finally {
|
||||
@@ -260,7 +260,7 @@ export function usePropertyOwners() {
|
||||
value: company.id
|
||||
}))
|
||||
);
|
||||
} catch (error) {
|
||||
} catch (error: unknown) {
|
||||
console.error('Error fetching property owners:', error);
|
||||
setPropertyOwners([]);
|
||||
} finally {
|
||||
|
||||
Reference in New Issue
Block a user