Moved second_curtain invocation to end of the pipe.