refactor to disable testing / development features from production, add more authentication checks