Skip to content

Commit

Permalink
Avoid using Object.fromEntries to fix the error
Browse files Browse the repository at this point in the history
  • Loading branch information
Issei Horie committed May 5, 2020
1 parent 2bf589d commit 65b8663
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/generator/src/utils/fetch-latest-version-for.ts
Expand Up @@ -26,6 +26,8 @@ export const fetchLatestVersionsFor = async <T extends Record<string, string>>(

return {
isFallback: fallbackUsed,
value: Object.fromEntries(updated),
value: updated.reduce((result, [key, value]) => {
return Object.assign({}, result, {[key]: value})
}, {} as T),
}
}

0 comments on commit 65b8663

Please sign in to comment.