diff --git a/fanficfare/adapters/adapter_fictionlive.py b/fanficfare/adapters/adapter_fictionlive.py index f374fd52..f29aebc7 100644 --- a/fanficfare/adapters/adapter_fictionlive.py +++ b/fanficfare/adapters/adapter_fictionlive.py @@ -269,10 +269,11 @@ class FictionLiveAdapter(BaseSiteAdapter): # doesn't actually run without the call to list. list(map(add_chapter_url, titles, pair(times))) - for a in appendices: # add appendices afterwards - chapter_start = a['ct'] - chapter_title = "Appendix: " + a['title'][9:] # 'Appendix: ' rather than '#special' at beginning of name - add_chapter_url(chapter_title, (chapter_start, chapter_start + 2)) # 1 msec range = this one chunk only + if self.getConfig('include_appendices', True): # Only add appendices if desired + for a in appendices: # add appendices afterwards + chapter_start = a['ct'] + chapter_title = "Appendix: " + a['title'][9:] # 'Appendix: ' rather than '#special' at beginning of name + add_chapter_url(chapter_title, (chapter_start, chapter_start + 2)) # 1 msec range = this one chunk only for r in routes: # add route at the end, after appendices route_id = r['id'] # to get route chapter content, the route id is needed, not the timestamp diff --git a/fanficfare/configurable.py b/fanficfare/configurable.py index d16f68de..3411b764 100644 --- a/fanficfare/configurable.py +++ b/fanficfare/configurable.py @@ -239,6 +239,8 @@ def get_valid_set_options(): 'skip_author_cover':(ffnet_list,None,boollist), 'try_shortened_title_urls':(['fanfiction.net'],None,boollist), + 'include_appendices':(['fiction.live'],None,boollist), + 'fix_fimf_blockquotes':(['fimfiction.net'],None,boollist), 'keep_prequel_in_description':(['fimfiction.net'],None,boollist), 'scrape_bookshelf':(['fimfiction.net'],None,boollist+['legacy']), @@ -609,6 +611,7 @@ def get_valid_keywords(): 'fix_excess_space', 'dedup_order_chapter_list', 'ignore_chapter_url_list', + 'include_appendices', 'dedup_chapter_list', 'show_timestamps', 'show_nsfw_cover_images', diff --git a/fanficfare/defaults.ini b/fanficfare/defaults.ini index 5f1c012c..118841e4 100644 --- a/fanficfare/defaults.ini +++ b/fanficfare/defaults.ini @@ -2061,6 +2061,9 @@ likes_label:Likes reader_input_label:Reader Input keep_in_order_tags:true +# Choose whether to include Appendix chapters +include_appendices:true + add_to_keep_html_attrs:,style add_to_output_css: