diff --git a/CHANGELOG.md b/CHANGELOG.md index 9a933c1d1..33c9d3355 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,8 @@ the navbar beneath posts that lets you move to the next or previous post in a tag search. Previously this was only available to logged-in users. +* Removed the option to disable the next/previous post navbar. + ## 2021-01-12 ### Changes diff --git a/app/models/user.rb b/app/models/user.rb index d4044c6c6..152f55558 100644 --- a/app/models/user.rb +++ b/app/models/user.rb @@ -671,7 +671,6 @@ class User < ApplicationRecord def initialize_attributes self.enable_post_navigation = true self.new_post_navigation_layout = true - self.enable_sequential_post_navigation = true self.enable_auto_complete = true self.always_resize_images = true end diff --git a/app/policies/user_policy.rb b/app/policies/user_policy.rb index 58d6b654e..e21352bce 100644 --- a/app/policies/user_policy.rb +++ b/app/policies/user_policy.rb @@ -45,12 +45,11 @@ class UserPolicy < ApplicationPolicy :blacklisted_tags, :time_zone, :per_page, :custom_style, :theme, :receive_email_notifications, :always_resize_images, :enable_post_navigation, :new_post_navigation_layout, - :enable_private_favorites, :enable_sequential_post_navigation, - :hide_deleted_posts, :style_usernames, :enable_auto_complete, - :show_deleted_children, :disable_categorized_saved_searches, - :disable_tagged_filenames, :disable_cropped_thumbnails, - :disable_mobile_gestures, :enable_safe_mode, :enable_desktop_mode, - :disable_post_tooltips, + :enable_private_favorites, :hide_deleted_posts, :style_usernames, + :enable_auto_complete, :show_deleted_children, + :disable_categorized_saved_searches, :disable_tagged_filenames, + :disable_cropped_thumbnails, :disable_mobile_gestures, :enable_safe_mode, + :enable_desktop_mode, :disable_post_tooltips, ].compact end diff --git a/app/presenters/post_presenter.rb b/app/presenters/post_presenter.rb index 23fee57c1..9c098859e 100644 --- a/app/presenters/post_presenter.rb +++ b/app/presenters/post_presenter.rb @@ -25,6 +25,6 @@ class PostPresenter def has_sequential_navigation?(params) return false if PostQueryBuilder.new(params[:q]).has_metatag?(:order, :ordfav, :ordpool) return false if params[:pool_id].present? || params[:favgroup_id].present? - return CurrentUser.user.enable_sequential_post_navigation + true end end diff --git a/app/views/users/edit.html.erb b/app/views/users/edit.html.erb index 798ae62c7..572d9985d 100644 --- a/app/views/users/edit.html.erb +++ b/app/views/users/edit.html.erb @@ -60,7 +60,6 @@ <%= f.input :style_usernames, :as => :select, :label => "Colored usernames", :hint => "Color users according to their user level", :include_blank => false, :collection => [["Yes", "true"], ["No", "false"]] %> <%= f.input :enable_post_navigation, :as => :select, :include_blank => false, :label => "Enable keyboard shortcuts", :hint => "Enable keyboard shortcuts", :collection => [["Yes", "true"], ["No", "false"]] %> - <%= f.input :enable_sequential_post_navigation, :as => :select, :label => "Enable post navigation", :hint => "Show prev/next links when viewing a post", :include_blank => false, :collection => [["Yes", "true"], ["No", "false"]] %> <%= f.input :new_post_navigation_layout, :as => :select, :label => "Navigation bar position", :include_blank => false, :collection => [["Below", "true"], ["Above", "false"]], :hint => "When browsing pools or posts, place navigation links above or below the image" %> <%= f.input :hide_deleted_posts, :as => :select, :label => "Deleted post filter", :hint => "Remove deleted posts from search results", :include_blank => false, :collection => [["Yes", "true"], ["No", "false"]] %> <%= f.input :show_deleted_children, :as => :select, :label => "Show deleted children", :hint => "Show thumbnail borders on parent posts even if the children are deleted", :include_blank => false, :collection => [["Yes", "true"], ["No", "false"]] %>