mirror of
https://github.com/TandoorRecipes/recipes.git
synced 2025-12-24 02:39:20 -05:00
added exception catch to nextcloud importer
to handle empty folders in sync
This commit is contained in:
@@ -29,7 +29,11 @@ class Nextcloud(Provider):
|
||||
client = Nextcloud.get_client(monitor.storage)
|
||||
|
||||
files = client.list(monitor.path)
|
||||
files.pop(0) # remove first element because its the folder itself
|
||||
|
||||
try:
|
||||
files.pop(0) # remove first element because its the folder itself
|
||||
except IndexError:
|
||||
pass # folder is emtpy, no recipes will be imported
|
||||
|
||||
import_count = 0
|
||||
for file in files:
|
||||
|
||||
Reference in New Issue
Block a user