moar
This commit is contained in:
parent
352d7aa896
commit
ef45caa86f
@ -32,6 +32,11 @@ interface ErrorData {
|
||||
BuildNumber: number;
|
||||
}
|
||||
|
||||
interface ErroredResponse {
|
||||
total: number;
|
||||
packages: ErrorData[];
|
||||
}
|
||||
|
||||
interface PackagesResponse {
|
||||
total: number;
|
||||
packages: PackageData[];
|
||||
@ -111,8 +116,8 @@ const usePackageData = () => {
|
||||
setLoading(true);
|
||||
try {
|
||||
const response = await fetch('/api/errored');
|
||||
const data: ErrorData[] = await response.json();
|
||||
setErrPackages(data);
|
||||
const data: ErroredResponse = await response.json();
|
||||
setErrPackages(data.packages);
|
||||
} catch (error) {
|
||||
console.error("Error fetching errored:", error);
|
||||
setErrPackages([]);
|
||||
|
Loading…
Reference in New Issue
Block a user