rhazdon/django-sonic-screwdriver

View on GitHub
django_sonic_screwdriver/management/commands/cache:clear.py

Summary

Maintainability
A
0 mins
Test Coverage
from django.core.cache import cache
from django.core.management.base import BaseCommand


class Command(BaseCommand):
    """
    A simple management command which clears the site-wide cache.
    """

    help = "Fully clear site-wide cache."

    def handle(self, *args, **kwargs):
        cache.clear()
        self.stdout.write("Cache has been cleared!\n")