Fixes for public API and redirect admin