Projet

Général

Profil

0004-management-commands-tenant_command.py-only-consider-.patch

Christophe Siraut, 11 avril 2018 16:14

Télécharger (1,25 ko)

Voir les différences:

Subject: [PATCH 4/5] management/commands/tenant_command.py: only consider
 DISABLE_CRON_JOBS if --all-tenants is used

 hobo/multitenant/management/commands/tenant_command.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
hobo/multitenant/management/commands/tenant_command.py
48 48
            help='Run command even if DISABLE_CRON_JOBS is set' )
49 49
        args_namespace, args = args_parser.parse_known_args(argv)
50 50

  
51
        if not args_namespace.force_job and getattr(settings, 'DISABLE_CRON_JOBS', False):
51
        if args_namespace.all_tenants and not args_namespace.force_job \
52
           and getattr(settings, 'DISABLE_CRON_JOBS', False):
52 53
            if kwargs.get('verbosity') > 1:
53 54
                print('Command %s is ignored because DISABLE_CRON_JOBS is set'
54 55
                      % app_name)
55
-