react-native-webrtc / react-native-webrtc/react-native-callkeep

Duplicated methods

Open
#829 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
1.1k
Forks
511
Avg merge
9h 12m
Merged PRs (30d)
2

Description

Hi! 👋

Firstly, thanks for your work on this project! 🙂

Today I used patch-package to patch react-native-callkeep@4.3.16 for the project I'm working on.

Here is the diff that solved my problem:

diff --git a/node_modules/react-native-callkeep/android/src/main/java/io/wazo/callkeep/RNCallKeepModule.java b/node_modules/react-native-callkeep/android/src/main/java/io/wazo/callkeep/RNCallKeepModule.java
index 025480a..180dd47 100644
--- a/node_modules/react-native-callkeep/android/src/main/java/io/wazo/callkeep/RNCallKeepModule.java
+++ b/node_modules/react-native-callkeep/android/src/main/java/io/wazo/callkeep/RNCallKeepModule.java
@@ -434,10 +434,10 @@ public class RNCallKeepModule extends ReactContextBaseJavaModule implements Life
         this.hasListeners = false;
     }
 
-    @ReactMethod
-    public void displayIncomingCall(String uuid, String number, String callerName) {
-        this.displayIncomingCall(uuid, number, callerName, false, null);
-    }
+    // @ReactMethod
+    // public void displayIncomingCall(String uuid, String number, String callerName) {
+    //     this.displayIncomingCall(uuid, number, callerName, false, null);
+    // }
 
     @ReactMethod
     public void displayIncomingCall(String uuid, String number, String callerName, boolean hasVideo) {
@@ -488,10 +488,10 @@ public class RNCallKeepModule extends ReactContextBaseJavaModule implements Life
         this.startCall(uuid, number, callerName, false, null);
     }
 
-    @ReactMethod
-    public void startCall(String uuid, String number, String callerName, boolean hasVideo) {
-        this.startCall(uuid, number, callerName, hasVideo, null);
-    }
+    // @ReactMethod
+    // public void startCall(String uuid, String number, String callerName, boolean hasVideo) {
+    //     this.startCall(uuid, number, callerName, hasVideo, null);
+    // }
 
     public void startCall(String uuid, String number, String callerName, boolean hasVideo, @Nullable Bundle payload) {
         Log.d(TAG, "[RNCallKeepModule] startCall called, uuid: " + uuid + ", number: " + number + ", callerName: " + callerName + ", payload: " + payload);

This issue body was partially generated by patch-package.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open android/src/main/java/io/wazo/callkeep/RNCallKeepModule.java and inspect the reported displayIncomingCall and startCall overloads. Compare them with the supplied patch; done means the duplicated React Native methods are resolved in the project source and the Android module continues to build successfully.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, react-native
Domain
mobile
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.