Merge {$count} items

In the latest update (version 7.0.24, on OSX), when merging duplicates, the GUI button shows "Merge {$count} items" instead of interpolating the value and showing, e.g., "Merge 3 items".
  • Can you provide a Report ID?
  • Do you see this in Troubleshooting Mode (Help → "Restart in Troubleshooting Mode…”), which temporarily disables all plugins?
  • No I don't, I actually see the correct button text, e.g., "Merge 2 items"!

    FWIW the only plugin I have is Better Bibtex for Zotero.
  • Yes, we've seen this before with BBT, though I don't think we ever figured out the cause. @emilianoeheyns, any thoughts?
  • edited 20 days ago
    @benoitpasquier: If you restart Zotero in normal mode with BBT enabled, do you still see it?
  • I don't know, I am not interfering with the dialog or with Zotero translations. I am monkey-patching Zotero.Items.merge but I don't see how that could cause this.
  • Hi @emilianoeheyns,

    Doesn't mean to make the discussion too technical, but it might be the case that BBT is inserting FTL files while they are not properly removed when the plugin is shut down. See this as an example to remove the ftl files from the main window (which should also be called on plugin shutdown).
  • Undoubtedly the case. I am adding ftl as

    window.MozXULElement.insertFTLIfNeeded('better-bibtex.ftl')

    should that be removed as

    window.document
    .querySelector(`[href="better-bibtex.ftl"]`)
    ?.remove();

    ? And why in shutdown rather than onMainWindowUnload?
  • Found it. Added it to shutdown and mainwindow unload
  • @emilianoeheyns

    Yes.

    > And why in shutdown rather than onMainWindowUnload?

    When the plugin is disabled/updated/removed while the main window is still open, the FTL links pointing to invalid resources (which no longer exist since the plugin is shut down) may break the localization. For that reason, it is better to remove them in both onMainWindowUnload and shutdown.
  • That's what I have now
Sign In or Register to comment.