diff --git a/content/media/MediaRecorder.cpp b/content/media/MediaRecorder.cpp index adbb61689c7..32e1992c351 100644 --- a/content/media/MediaRecorder.cpp +++ b/content/media/MediaRecorder.cpp @@ -185,9 +185,7 @@ MediaRecorder::Start(const Optional& aTimeSlice, ErrorResult& aResult) mEncodedBufferCache = new EncodedBufferCache(MAX_ALLOW_MEMORY_BUFFER); } - if (mEncoder == nullptr) { - mEncoder = MediaEncoder::CreateEncoder(NS_LITERAL_STRING("")); - } + mEncoder = MediaEncoder::CreateEncoder(NS_LITERAL_STRING("")); MOZ_ASSERT(mEncoder, "CreateEncoder failed"); mTrackUnionStream->SetAutofinish(true);