Skip to content

Commit

Permalink
Merge pull request #93 from plaid/smaronesyMinorChanges
Browse files Browse the repository at this point in the history
added 2 imports and modified the instructions and code for link_token
  • Loading branch information
souhaylmaronesy authored Sep 14, 2020
2 parents b2715fb + 26e5a65 commit 0b17cc8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ To run the sample app, you'll need a Plaid account. You can create one on [our w
## 2a. Generate a link_token and add it to the sample app
1. Clone the sample repository
2. Curl [/link/token/create](https://plaid.com/docs/#create-link-token) to create a new link_token
3. Copy and paste the link_token into the [kotlin][get-link-token-kotlin] or [java][get-link-token-java] `getLinkToken()` function.
3. Copy and paste the link_token into the [kotlin][get-link-token-kotlin] or [java][get-link-token-java] LinkTokenRequester's `getToken()` function.

OR

Expand Down
2 changes: 2 additions & 0 deletions app/src/main/java/com/plaid/linksample/MainActivityJava.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@
import androidx.appcompat.app.AppCompatActivity;
import com.plaid.link.Plaid;
import com.plaid.link.configuration.LinkTokenConfiguration;
import com.plaid.link.configuration.PlaidProduct;
import com.plaid.link.result.PlaidLinkResultHandler;
import com.plaid.linksample.network.LinkTokenRequester;
import java.util.ArrayList;
import kotlin.Unit;

public class MainActivityJava extends AppCompatActivity {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,10 @@ object LinkTokenRequester {
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.map { it.link_token }
// Uncomment this to use a curled Link Token
//return Single.just("<GENERATED_LINK_TOKEN>")

// Comment out the above and uncomment the below to use a curled Link Token
// val token
// get() = Single.just("<GENERATED_LINK_TOKEN>")

}

0 comments on commit 0b17cc8

Please sign in to comment.