MCPcopy Create free account
hub / github.com/Pagghiu/SaneCppLibraries / onFinish

Method onFinish

Libraries/Http/HttpAsyncFileServer.cpp:372–381  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

370}
371
372void HttpAsyncFileServer::Stream::PutFileListener::onFinish()
373{
374 SC_HTTP_ASSERT_RELEASE(connection != nullptr);
375 AsyncWritableStream& writable = *connection->pipeline.sinks[0];
376 const bool removedFinishListener =
377 writable.eventFinish.removeListener<HttpAsyncFileServer::Stream::PutFileListener,
378 &HttpAsyncFileServer::Stream::PutFileListener::onFinish>(*this);
379 SC_HTTP_ASSERT_RELEASE(removedFinishListener);
380 SC_HTTP_ASSERT_RELEASE(connection->response.sendEmpty(201));
381}
382
383StringSpan HttpAsyncFileServer::Internal::getContentType(const HttpAsyncFileServerOptions& options,
384 const StringSpan extension)

Callers

nothing calls this directly

Calls 1

sendEmptyMethod · 0.80

Tested by

no test coverage detected