Skip to content

Commit

Permalink
Add RNBranchModule.getAutoInstance to README for new installs, not ju…
Browse files Browse the repository at this point in the history
…st update instructions
  • Loading branch information
jdee committed Feb 25, 2019
1 parent 8f4ccb3 commit 5ff830e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ ___
Add RNBranchPackage to packages list in `getPackages()` MainApplication.java (`android/app/src/[...]/MainApplication.java`).
Note that this is automatically done if you used `react-native link`.
Also add a call to `Branch.getAutoinstance()` in `onCreate()` in the same source file. This has to be
Also add a call to `RNBranchModule.getAutoinstance()` in `onCreate()` in the same source file. This has to be
done even if you used `react-native link`.
```java
// ...
Expand All @@ -276,10 +276,13 @@ import io.branch.referral.Branch;
@Override
public void onCreate() {
super.onCreate();
Branch.getAutoInstance(this);
RNBranchModule.getAutoInstance(this);
}
```
_NOTE_: `RNBranchModule.getAutoInstance` was introduced in version 3.0.0-beta.2. Use `Branch.getAutoInstance` in
previous versions, including 2.x.
Override onStart and onNewIntent in MainActivity.java to handle Branch links (`android/app/src/[...]/MainActivity.java`).
This has to be done regardless whether you used `react-native link`.
```java
Expand Down

0 comments on commit 5ff830e

Please sign in to comment.