Server socket event fixes

This commit is contained in:
Paul Nettleton 2022-12-22 16:26:11 -06:00
parent a9ee9031c3
commit 2cba83f1dd
6 changed files with 11 additions and 11 deletions

View file

@ -476,7 +476,7 @@ class ApiRouter {
}
if (newAuthors.length) {
await this.db.insertEntities('author', newAuthors)
SocketAuthority.emitter('authors_added', newAuthors)
SocketAuthority.emitter('authors_added', newAuthors.map(au => au.toJSON()))
}
}
@ -500,7 +500,7 @@ class ApiRouter {
}
if (newSeries.length) {
await this.db.insertEntities('series', newSeries)
SocketAuthority.emitter('authors_added', newSeries)
SocketAuthority.emitter('multiple_series_added', newSeries.map(se => se.toJSON()))
}
}
}