From 1e9fe12904e123ee6d33d007cf753515b582e6eb Mon Sep 17 00:00:00 2001 From: Markus Unterwaditzer Date: Sun, 22 Feb 2015 14:59:36 +0100 Subject: [PATCH] Another bugfix See #179 --- vdirsyncer/cli/utils.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/vdirsyncer/cli/utils.py b/vdirsyncer/cli/utils.py index 1a31e66..550577d 100644 --- a/vdirsyncer/cli/utils.py +++ b/vdirsyncer/cli/utils.py @@ -186,6 +186,7 @@ def _discover_from_config(config): def _handle_collection_not_found(config, collection, e=None): storage_name = config.get('instance_name', None) + assert config.setdefault('collection', collection) == collection cli_logger.error('{}No collection {} found for storage {}.' .format('{}\n'.format(e) if e else '', @@ -195,7 +196,7 @@ def _handle_collection_not_found(config, collection, e=None): storage_type = config['type'] cls, config = storage_class_from_config(config) try: - args = cls.create_collection(collection=collection, **config) + args = cls.create_collection(**config) args['type'] = storage_type return args except NotImplementedError as e: