style: fix formatting in v2 files
This commit is contained in:
3 files changed
+6
-9
No files matched your search
@@ -52,9 +52,9 @@ const mapOsDistributionEntry = (
|
||||
osVersion: entry.os_version,
|
||||
});
|
||||
|
||||
export const parsePatchMonStatsResponseAsync = async (
|
||||
response: { json: () => Promise<unknown> },
|
||||
): Promise<z.infer<typeof patchmonStatsResponseSchema>> => {
|
||||
export const parsePatchMonStatsResponseAsync = async (response: {
|
||||
json: () => Promise<unknown>;
|
||||
}): Promise<z.infer<typeof patchmonStatsResponseSchema>> => {
|
||||
let json: unknown;
|
||||
try {
|
||||
json = await response.json();
|
||||
@@ -82,7 +82,5 @@ export const mapPatchMonStats = (data: z.infer<typeof patchmonStatsResponseSchem
|
||||
totalOutdatedPackages: data.total_outdated_packages,
|
||||
totalRepos: data.total_repos,
|
||||
lastUpdated: data.last_updated,
|
||||
osDistribution: [...data.os_distribution]
|
||||
.map(mapOsDistributionEntry)
|
||||
.sort((a, b) => b.count - a.count),
|
||||
osDistribution: [...data.os_distribution].map(mapOsDistributionEntry).sort((a, b) => b.count - a.count),
|
||||
});
|
||||
Reference in new issue
Block a user