Sefaria / Sefaria-Project

New Interfaces for Jewish Texts
https://www.sefaria.org
654 stars 268 forks source link

Bug/sc 28476/error when trying to add captions for images #1969

Closed yonadavGit closed 2 months ago

yonadavGit commented 2 months ago

Description

The "disambiguation" field of topic titles was not sent to the client. As a result, when editing a topic with disambiguations in its title, the inconsistency prevented the server from properly updating the topic object. This PR fixes the issue by making the client extract the disambiguation from the title string and format the title object similarly to how it is represented in the database. The server code was also modified to accommodate the new format.

Code Changes

update_topic_titles in server prepData in TopicEditor.jsx