mirror of
https://github.com/kiwix/kiwix-android.git
synced 2025-09-08 14:52:13 -04:00
Fixed #3519.
* The problem was that we were saving the note name combined with `zimFileTitle` and `articleTitle`. When opening the saved note from `NotesFragment`, it retrieved the `noteTitle` from the database, which already contained the combined name. Subsequently, when saving the note again, it redundantly combined the name. To resolve this issue, we now extract the `articleName` when updating notes in `NotesFragment`, ensuring that it updates existing notes instead of creating new ones.
This commit is contained in:
parent
b6d718f287
commit
845f19eab6
@ -123,7 +123,7 @@ class AddNoteDialog : DialogFragment() {
|
||||
zimId = zimReaderContainer.id.orEmpty()
|
||||
|
||||
if (arguments != null) {
|
||||
articleTitle = arguments?.getString(NOTES_TITLE)
|
||||
articleTitle = arguments?.getString(NOTES_TITLE)?.substringAfter(": ")
|
||||
zimFileUrl = arguments?.getString(ARTICLE_URL).orEmpty()
|
||||
} else {
|
||||
val webView = (activity as WebViewProvider?)?.getCurrentWebView()
|
||||
|
Loading…
x
Reference in New Issue
Block a user