fix: values().map is undefined

This commit is contained in:
DIYgod 2024-12-12 18:01:33 +08:00
parent 96b892923a
commit 74ba483b0d
No known key found for this signature in database
2 changed files with 2 additions and 2 deletions

View File

@ -213,7 +213,7 @@ export const useFeedActions = ({
disabled: isInbox,
supportMultipleSelection: true,
submenu: [
...categories.values().map((category) => {
...Array.from(categories.values()).map((category) => {
const isIncluded = isMultipleSelection
? subscriptions.every((s) => s.category === category)
: subscription?.category === category

View File

@ -62,7 +62,7 @@ async function cleanSources(buildPath, electronVersion, platform, arch, callback
// copy needed node_modules to be included in the app
await Promise.all(
keepModules.values().map((item) => {
Array.from(keepModules.values()).map((item) => {
// Check is exist
if (fs.existsSync(path.join(buildPath, "node_modules", item))) {
// eslint-disable-next-line array-callback-return