kometenstaub / obsidian-version-history-diff

Get a diff view of your Obsidian Sync, File Recovery and Git version history
MIT License
115 stars 5 forks source link

Sync history and Sync diff don't work : Cannot read properties of null (reading 'listHistory') #12

Open cjunekim opened 2 years ago

cjunekim commented 2 years ago

Hello

Show Git Diff view for active file works well without an issue. However, Show Sync history for active file and Show Sync diff view for active file don't work at all showing an empty window. (BTW, I don't exactly know what they do actually)

The developer's console shows the following error:

Uncaught (in promise) TypeError: Cannot read properties of null (reading 'listHistory')
    at t.<anonymous> (app.js:1:1970557)
    at app.js:1:235078
    at Object.next (app.js:1:235183)
    at s (app.js:1:233922)

Obsidian Git version : 1.28.0 Version History Diff version : 2.0.5 Obsidian App version : 0.15.9 OS : Windows 10 21H2

cjunekim commented 2 years ago

I am answering myself. Sync history and Sync diff seem to be related to the core plugin Sync, and if you don't use it, the result being empty is right -- however, it would be better to display some message instead, something like "Sync is not enabled" or so.

kometenstaub commented 1 year ago

Conditionally enabling these commands would probably make sense, yes.