properly splitting admin code and public code