from django.core.management.base import BaseCommand
from REST.models import User

class Command(BaseCommand):

    def handle(self, *args, **options):
        if not User.objects.filter(email="<EMAIL>").exists():
            User.objects.create_superuser("<EMAIL>", "<PASSWORD>")
from django.core.management.base import BaseCommand
from REST.models import User

class Command(BaseCommand):

    def handle(self, *args, **options):
        if not User.objects.filter(email="<EMAIL>").exists():
            User.objects.create_superuser("<EMAIL>", "<PASSWORD>")