We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d8ba3b4 commit 6b5e775Copy full SHA for 6b5e775
packages/mlkit-core/index.android.ts
@@ -251,7 +251,9 @@ export class MLKitView extends MLKitViewBase {
251
}
252
253
if (!this.#onFaceListener && (this.detectionType === DetectionType.Face || this.detectionType === DetectionType.All)) {
254
- this.#faceDetectionOptions = new io.github.triniwiz.fancycamera.facedetection.FaceDetection.Options();
+ if (FACE_DETECTION_SUPPORTED()) {
255
+ this.#faceDetectionOptions = new io.github.triniwiz.fancycamera.facedetection.FaceDetection.Options();
256
+ }
257
this.#onFaceListener = new io.github.triniwiz.fancycamera.ImageAnalysisCallback({
258
onSuccess(param0: string) {
259
const hasListener = ref?.get?.().hasListeners?.(MLKitView.detectionEvent);
0 commit comments