Skip to content

Commit

Permalink
changed arg setBlockAds
Browse files Browse the repository at this point in the history
  • Loading branch information
Pingou committed Oct 31, 2023
1 parent c77f785 commit 46d2405
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -369,9 +369,11 @@ private void loadAdlist(Context context) {
}

@ReactProp(name = "blockAds")
public void setBlockAds(RNCWebView view, boolean enable) {
if (enable)
this.loadAdlist(view.getContext());
public void setBlockAds(RNCWebViewWrapper view, boolean enable) {
if (enable) {
this.loadAdlist(view.getWebView().getContext());
}

}

/* iOS PROPS - no implemented here */
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -316,9 +316,9 @@ private void loadAdlist(Context context) {
}

@ReactProp(name = "blockAds")
public void setBlockAds(RNCWebView view, boolean enable) {
public void setBlockAds(RNCWebViewWrapper view, boolean enable) {
if (enable)
this.loadAdlist(view.getContext());
this.loadAdlist(view.getWebView().getContext());
}

@Override
Expand Down

0 comments on commit 46d2405

Please sign in to comment.