mirror of
https://github.com/arsenetar/dupeguru.git
synced 2025-03-09 21:24:36 +00:00
[#48 state:fixed] Gracefully handle cases where the library doesn't exist in Add iPhoto Library.
--HG-- extra : convert_revision : svn%3Ac306627e-7827-47d3-bdf0-9a457c9553a1/trunk%40114
This commit is contained in:
parent
36f9e21184
commit
497a29118a
@ -19,7 +19,7 @@ from appscript import app, k
|
||||
|
||||
from hsutil import job, io
|
||||
import hsfs as fs
|
||||
from hsfs import phys
|
||||
from hsfs import phys, InvalidPath
|
||||
from hsutil import files
|
||||
from hsutil.str import get_file_ext
|
||||
from hsutil.path import Path
|
||||
@ -94,6 +94,8 @@ class IPhotoLibrary(fs.Directory):
|
||||
self.refpath = plistpath[:-1]
|
||||
# the AlbumData.xml file lives right in the library path
|
||||
super(IPhotoLibrary, self).__init__(None, 'iPhoto Library')
|
||||
if not io.exists(plistpath):
|
||||
raise InvalidPath(self)
|
||||
|
||||
def _update_photo(self, photo_data):
|
||||
if photo_data['MediaType'] != 'Image':
|
||||
|
Loading…
x
Reference in New Issue
Block a user