toupper / Wyler

Screen Recording Made Easy on iOS
MIT License
67 stars 11 forks source link

Cannot refuse to start and then start again and allow #7

Open riderx opened 2 years ago

riderx commented 2 years ago

if user refuse to allow recorder and user click again to start and allow recorder

        implementation.startRecording(saveToCameraRoll: true, errorHandler: { error in
            debugPrint("Error when recording \(error)")
        })

I get this error the second time :

2021-12-02 20:28:40.423860+0000 App[6134:9790803]  [ERROR] -[RPScreenRecorder startCaptureWithHandler:completionHandler:]_block_invoke_2:482 failed to start due to error: Error Domain=com.apple.ReplayKit.RPRecordingErrorDomain Code=-5801 "The user declined application recording" UserInfo={NSLocalizedDescription=The user declined application recording}
2021-12-02 20:28:40.424106+0000 App[6134:9790237]  [ERROR] -[RPScreenRecorder startCaptureWithHandler:completionHandler:]_block_invoke:505 undefined completion handler
riderx commented 2 years ago

Fixed here : https://github.com/toupper/Wyler/pull/8