<reponame>gurleens2000/mercantile<filename>store/admin.py
from django.contrib import admin
from django.apps import apps
from django.contrib.admin.sites import AlreadyRegistered


app_models = apps.get_app_config("store").get_models()

for model in app_models:
    try:
        admin.site.register(model)
    except AlreadyRegistered:
        pass

from django.contrib import admin
from django.apps import apps
from django.contrib.admin.sites import AlreadyRegistered


app_models = apps.get_app_config("store").get_models()

for model in app_models:
    try:
        admin.site.register(model)
    except AlreadyRegistered:
        pass