switchCamera method
Switches between front and back camera.
Implementation
Future<void> switchCamera() async {
try {
await CometChatCallsPluginPlatform.instance.nativeSwitchCamera();
} catch (e) {
throw CometChatCallsException(
ErrorCodeConstants.errorSwitchCamera,
'Failed to switch camera',
e.toString(),
);
}
}