write('Please call this only from CLI'); return $response->withHeader('Content-Type', 'text/plain')->withStatus(400); } else { $response = $next($request, $response); return $response->withHeader('Content-Type', 'text/plain'); } } }