Content server: Fix editing metadata that affects multiple books causing all the metadata for all the books to become the same.

Fixes #1812781 [400 bad request from server API](https://bugs.launchpad.net/calibre/+bug/1812781)
This commit is contained in:
Kovid Goyal 2019-01-30 09:26:44 +05:30
parent 6ff8b2a97a
commit d8ff047cb9
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -175,7 +175,7 @@ def cdb_set_fields(ctx, rd, book_id, library_id):
ctx.notify_changes(db.backend.library_path, metadata(dirtied))
all_ids = dirtied if all_dirtied else (dirtied & loaded_book_ids)
all_ids |= {book_id}
return {bid: book_as_json(db, book_id) for bid in all_ids}
return {bid: book_as_json(db, bid) for bid in all_ids}
@endpoint('/cdb/copy-to-library/{target_library_id}/{library_id=None}', needs_db_write=True,