Terminate the app middleware

From the discussion at <a href="https://laracasts.com/discuss/channels/general-discussion/l5-codecept-broken-since-bootstrapstartphp-removed">laracast</a> I found that the middleware isn't terminated properly. This fixes it.