diff options
Diffstat (limited to 'app/src/main')
-rw-r--r-- | app/src/main/java/ml/docilealligator/infinityforreddit/Adapter/SubredditListingRecyclerViewAdapter.java | 2 | ||||
-rw-r--r-- | app/src/main/java/ml/docilealligator/infinityforreddit/ParsePost.java | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/Adapter/SubredditListingRecyclerViewAdapter.java b/app/src/main/java/ml/docilealligator/infinityforreddit/Adapter/SubredditListingRecyclerViewAdapter.java index ccca819d..21646e8d 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/Adapter/SubredditListingRecyclerViewAdapter.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/Adapter/SubredditListingRecyclerViewAdapter.java @@ -121,7 +121,7 @@ public class SubredditListingRecyclerViewAdapter extends PagedListAdapter<Subred ((DataViewHolder) holder).subscribeButton.setVisibility(View.VISIBLE); ((DataViewHolder) holder).subscribeButton.setOnClickListener(view -> { SubredditSubscription.subscribeToSubreddit(oauthRetrofit, retrofit, - accessToken, accountName, subredditData.getName(), redditDataRoomDatabase, + accessToken, subredditData.getName(), accountName, redditDataRoomDatabase, new SubredditSubscription.SubredditSubscriptionListener() { @Override public void onSubredditSubscriptionSuccess() { diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/ParsePost.java b/app/src/main/java/ml/docilealligator/infinityforreddit/ParsePost.java index ef79dc90..09259c98 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/ParsePost.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/ParsePost.java @@ -121,8 +121,8 @@ public class ParsePost { } else { String selfTextPlain = Utils.trimTrailingWhitespace( Html.fromHtml(data.getString(JSONUtils.SELFTEXT_HTML_KEY))).toString(); - if (selfTextPlain.length() > 150) { - selfTextPlain = selfTextPlain.substring(150); + if (selfTextPlain.length() > 250) { + selfTextPlain = selfTextPlain.substring(0, 250); } post.setSelfTextPlainTrimmed(selfTextPlain); } @@ -217,8 +217,8 @@ public class ParsePost { } else { String selfTextPlain = Utils.trimTrailingWhitespace( Html.fromHtml(data.getString(JSONUtils.SELFTEXT_HTML_KEY))).toString(); - if (selfTextPlain.length() > 150) { - selfTextPlain = selfTextPlain.substring(150); + if (selfTextPlain.length() > 250) { + selfTextPlain = selfTextPlain.substring(0, 250); } post.setSelfTextPlainTrimmed(selfTextPlain); } |