From 73af4090998d6c9465c6a64d30499d713b3b3859 Mon Sep 17 00:00:00 2001 From: Docile-Alligator <25734209+Docile-Alligator@users.noreply.github.com> Date: Fri, 26 Jan 2024 09:36:27 -0500 Subject: Fix a bug in FilteredPostsActivity. --- .../infinityforreddit/activities/FilteredPostsActivity.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'app/src/main/java/ml/docilealligator') diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/activities/FilteredPostsActivity.java b/app/src/main/java/ml/docilealligator/infinityforreddit/activities/FilteredPostsActivity.java index 4a28efcb..3df23f15 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/activities/FilteredPostsActivity.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/activities/FilteredPostsActivity.java @@ -167,7 +167,6 @@ public class FilteredPostsActivity extends BaseActivity implements SortTypeSelec PostFilter postFilter = getIntent().getParcelableExtra(EXTRA_CONSTRUCTED_POST_FILTER); if (postFilter == null) { postFilter = new PostFilter(); - postFilter.allowNSFW = !mSharedPreferences.getBoolean(SharedPreferencesUtils.DISABLE_NSFW_FOREVER, false) && mNsfwAndSpoilerSharedPreferences.getBoolean((mAccountName.equals(Account.ANONYMOUS_ACCOUNT) ? "" : mAccountName) + SharedPreferencesUtils.NSFW_BASE, false); switch (filter) { case Post.NSFW_TYPE: postFilter.onlyNSFW = true; @@ -227,6 +226,7 @@ public class FilteredPostsActivity extends BaseActivity implements SortTypeSelec postFilter.containFlairs = flair; } } + postFilter.allowNSFW = !mSharedPreferences.getBoolean(SharedPreferencesUtils.DISABLE_NSFW_FOREVER, false) && mNsfwAndSpoilerSharedPreferences.getBoolean((mAccountName.equals(Account.ANONYMOUS_ACCOUNT) ? "" : mAccountName) + SharedPreferencesUtils.NSFW_BASE, false); if (postType == PostPagingSource.TYPE_USER) { userWhere = getIntent().getStringExtra(EXTRA_USER_WHERE); -- cgit v1.2.3