File tree 1 file changed +14
-10
lines changed
1 file changed +14
-10
lines changed Original file line number Diff line number Diff line change @@ -317,14 +317,18 @@ func (m *model) getFilePanelItems() {
317
317
}
318
318
319
319
func (m model ) quitSuperfile () {
320
- // cd on quit
321
- if Config .CdOnQuit {
322
- currentDir := m .fileModel .filePanels [m .filePanelFocusIndex ].location
323
- if currentDir == variable .HomeDir {
324
- return
325
- }
326
- // escape single quote
327
- currentDir = strings .ReplaceAll (currentDir , "'" , "'\\ ''" )
328
- os .WriteFile (variable .SuperFileStateDir + "/lastdir" , []byte ("cd '" + currentDir + "'" ), 0755 )
329
- }
320
+ // close exiftool session
321
+ if Config .Metadata {
322
+ et .Close ();
323
+ }
324
+ // cd on quit
325
+ if Config .CdOnQuit {
326
+ currentDir := m .fileModel .filePanels [m .filePanelFocusIndex ].location
327
+ if currentDir == variable .HomeDir {
328
+ return
329
+ }
330
+ // escape single quote
331
+ currentDir = strings .ReplaceAll (currentDir , "'" , "'\\ ''" )
332
+ os .WriteFile (variable .SuperFileStateDir + "/lastdir" , []byte ("cd '" + currentDir + "'" ), 0755 )
333
+ }
330
334
}
You can’t perform that action at this time.
0 commit comments