Skip to content

Commit e41acde

Browse files
authored
fix: repository field not saved in db
1 parent fe8b1f8 commit e41acde

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

server/apis/plugin.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -431,6 +431,10 @@ router.post('/', async (req, res) => {
431431
insert.push([Plugin.KEYWORDS, JSON.stringify(pluginJson.keywords)]);
432432
}
433433

434+
if (pluginJson.repository) {
435+
insert.push([Plugin.REPOSITORY, pluginJson.repository]);
436+
}
437+
434438
await Plugin.insert(...insert);
435439

436440
savePlugin(pluginId, pluginZip, icon);
@@ -504,6 +508,10 @@ router.put('/', async (req, res) => {
504508
updates.push([Plugin.KEYWORDS, JSON.stringify(pluginJson.keywords)]);
505509
}
506510

511+
if (pluginJson.repository) {
512+
updates.push([Plugin.REPOSITORY, pluginJson.repository]);
513+
}
514+
507515
if (pluginJson.changelogs) {
508516
updates.push([Plugin.CHANGELOGS, pluginJson.changelogs]);
509517
}

0 commit comments

Comments
 (0)