Bug 15888 - Syndetics Reviews preference should not enable LibraryThing reviews
Summary: Syndetics Reviews preference should not enable LibraryThing reviews
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Nick Clemens
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-02-23 20:14 UTC by Nick Clemens
Modified: 2016-12-05 21:25 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments
Bug 15888 - Syndetics Reviews preference should not enable LibraryThing reviews (3.97 KB, patch)
2016-02-23 20:55 UTC, Nick Clemens
Details | Diff | Splinter Review
Bug 15888 - Syndetics Reviews preference should not enable LibraryThing reviews (4.02 KB, patch)
2016-03-02 08:29 UTC, Chris Cormack
Details | Diff | Splinter Review
[PASSED QA] Bug 15888 - Syndetics Reviews preference should not enable LibraryThing reviews (4.09 KB, patch)
2016-03-24 07:04 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Clemens 2016-02-23 20:14:34 UTC
On opac-detail.pl the code below attempts to retrieve LibraryThing content when SyndeticsReviews are enabled even if the librarything prefs are not turned on

 564    [% IF ( SyndeticsReviews && SYNDETICS_REVIEWS ) %]
 565        <li id="tab_reviews"> <a href="#reviews">Reviews</a></li>
 566        <li id="tab_LTFLreviews">
 567            [% IF ( using_https ) %]
 568               <script src="https://www.librarything.com/forlibraries/widget.js?id=[% LibraryThingForLibrariesID %]" type="text/javascript"></script>
 569               <noscript>This page contains enriched content visible when JavaScript is enabled or by clicking <a href="https://www.librarything.com/forlibraries/noscript.php?id=[% LibraryThingForLibrariesID %]&amp;accessibility=1">here</a>.</noscript>
 570            [% ELSE %]
 571               <script src="http://www.librarything.com/forlibraries/widget.js?id=[% LibraryThingForLibrariesID %]" type="text/javascript"></script>
 572               <noscript>This page contains enriched content visible when JavaScript is enabled or by clicking <a href="http://www.librarything.com/forlibraries/noscript.php?id=[% LibraryThingForLibrariesID %]&amp;accessibility=1">here</a>.</noscript>
 573            [% END %]
 57        </li>
 575     [% END %]
Comment 1 Nick Clemens 2016-02-23 20:55:53 UTC Comment hidden (obsolete)
Comment 2 Chris Cormack 2016-03-02 08:29:15 UTC Comment hidden (obsolete)
Comment 3 Katrin Fischer 2016-03-24 07:04:56 UTC
Created attachment 49519 [details] [review]
[PASSED QA] Bug 15888 - Syndetics Reviews preference should not enable LibraryThing reviews

To test:
1 - Enable Syndetics Reviews without a LibraryThing ID
2 - Check page source and note you have a stanza for LTFL tabbed reveiws
3 - Apply patch
4 - Reload page and note LTFL tabbed reviews are not present
5 - Enter a LibraryThing ID and not the tab is restored.

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 4 Brendan Gallagher 2016-03-24 16:08:04 UTC
Pushed to Master - Should be in May 2016 release.  Thanks!
Comment 5 Julian Maurice 2016-04-07 05:48:48 UTC
Patch pushed to 3.22.x, will be in 3.22.6
Comment 6 Frédéric Demians 2016-04-27 15:37:26 UTC
Pushed to 3.20.x, will be in 3.20.11.