Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Fix imports style and made feed_name optional
Krzysztof Wolski15914cc8bd29
diff --git a/saleor/integrations/management/commands/update_integrations.py b/saleor/integrations/management/commands/update_integrations.pyindex 414c9f8e3e..d4173a5809 100644--- a/saleor/integrations/management/commands/update_integrations.py+++ b/saleor/integrations/management/commands/update_integrations.py@@ -2,19 +2,20 @@ from __future__ import unicode_literalsfrom django.core.management import CommandError, BaseCommand-from saleor.integrations.feeds import SaleorFeed-from saleor.integrations import utils+from ....integrations.feeds import SaleorFeed+from ....integrations import utilsclass Command(BaseCommand):- help = 'Updates integration feeds. '+ help = ('Updates integration feeds.'+ 'If feed name not provided, updates all available feeds')feed_classes = {'saleor': SaleorFeed}def add_arguments(self, parser):- parser.add_argument('feed_name', nargs='+', type=str)+ parser.add_argument('feed_name', nargs='*', type=str, default=None)def handle(self, *args, **options):- feed_names = options['feed_name'] or self.feed_classes.keys()+ feed_names = options.get('feed_name') or self.feed_classes.keys()for feed_name in feed_names:feed = self.feed_classes.get(feed_name)if feed is None: