fix admin.py after refactoring