diff --git a/resources/default_tweaks.py b/resources/default_tweaks.py index 6fa13b1fb6..efb88cfcb3 100644 --- a/resources/default_tweaks.py +++ b/resources/default_tweaks.py @@ -342,29 +342,6 @@ sony_collection_sorting_rules = [] # a book' are added when copying books to another library add_new_book_tags_when_importing_books = False -#: Set custom metadata fields that the Content server will or will not display. -# Controls what fields are displayed when clicking the "Search" button in the -# browser to search your calibre library. -# content_server_will_display is a list of custom fields to be displayed. -# content_server_wont_display is a list of custom fields not to be displayed. -# wont_display has priority over will_display. -# The special value '*' means all custom fields. The value [] means no entries. -# Defaults: -# content_server_will_display = ['*'] -# content_server_wont_display = [] -# -# Examples: -# -# To display only the custom fields #mytags and #genre: -# content_server_will_display = ['#mytags', '#genre'] -# content_server_wont_display = [] -# -# To display all fields except #mycomments: -# content_server_will_display = ['*'] -# content_server_wont_display['#mycomments'] -content_server_will_display = ['*'] -content_server_wont_display = [] - #: Set the maximum number of sort 'levels' # Set the maximum number of sort 'levels' that calibre will use to resort the # library after certain operations such as searches or device insertion. Each diff --git a/src/calibre/srv/utils.py b/src/calibre/srv/utils.py index f07d646c28..f66c25c189 100644 --- a/src/calibre/srv/utils.py +++ b/src/calibre/srv/utils.py @@ -13,7 +13,6 @@ from operator import itemgetter from calibre import prints from calibre.constants import iswindows, ispy3 from calibre.srv.errors import HTTPNotFound -from calibre.utils.config_base import tweaks from calibre.utils.localization import get_translator from calibre.utils.socket_inheritance import set_socket_inherit from calibre.utils.logging import ThreadSafeLog @@ -298,14 +297,7 @@ class Cookie(SimpleCookie): def custom_fields_to_display(db): - ckeys = set(db.field_metadata.ignorable_field_keys()) - yes_fields = set(tweaks['content_server_will_display']) - no_fields = set(tweaks['content_server_wont_display']) - if '*' in yes_fields: - yes_fields = ckeys - if '*' in no_fields: - no_fields = ckeys - return frozenset(ckeys & (yes_fields - no_fields)) + return frozenset(db.field_metadata.ignorable_field_keys()) # Logging {{{