Skip to content

Commit 7948414

Browse files
committed
Ignore warnings
1 parent 784e16f commit 7948414

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

packages/camera/camera_avfoundation/ios/camera_avfoundation/Sources/camera_avfoundation/CaptureOutput.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ extension AVCaptureVideoDataOutput: CaptureVideoDataOutput {
4040
return self
4141
}
4242

43-
func connection(with mediaType: AVMediaType) -> (any CaptureConnection)? {
43+
func connection(with mediaType: AVMediaType) -> CaptureConnection? {
4444
let connection: AVCaptureConnection? = connection(with: mediaType)
4545
return connection
4646
}

packages/camera/camera_avfoundation/ios/camera_avfoundation/Sources/camera_avfoundation/DefaultCamera.swift

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -510,7 +510,8 @@ final class DefaultCamera: NSObject, Camera {
510510
// didOutputSampleBuffer had chance to call startWriting and lag at start of video
511511
// https://github.com/flutter/flutter/issues/132016
512512
// https://github.com/flutter/flutter/issues/151319
513-
videoWriter?.startWriting()
513+
// Result ignored in line with the Objective-C implementation
514+
let _ = videoWriter?.startWriting()
514515
isFirstVideoSample = true
515516
isRecording = true
516517
isRecordingPaused = false
@@ -1219,7 +1220,8 @@ final class DefaultCamera: NSObject, Camera {
12191220
// do not append sample buffer when readyForMoreMediaData is NO to avoid crash
12201221
// https://github.com/flutter/flutter/issues/132073
12211222
if videoWriterInput?.isReadyForMoreMediaData ?? false {
1222-
videoAdaptor?.append(nextBuffer!, withPresentationTime: nextSampleTime)
1223+
// Result ignored in line with the Objective-C implementation
1224+
let _ = videoAdaptor?.append(nextBuffer!, withPresentationTime: nextSampleTime)
12231225
}
12241226
} else {
12251227
let dur = CMSampleBufferGetDuration(sampleBuffer)

0 commit comments

Comments
 (0)