Bug 16031: sitemap.pl shouldn't append protocol to OPACBaseURL
authorTomas Cohen Arazi <tomascohen@theke.io>
Wed, 9 Mar 2016 18:41:02 +0000 (15:41 -0300)
committerJulian Maurice <julian.maurice@biblibre.com>
Mon, 14 Mar 2016 09:30:42 +0000 (10:30 +0100)
commit808f938517e07f0dc75a755c77e0a114edf86ed0
tree340d2f897027a1b5347ee99cabdd8dfca8b41304
parent7db11e9565fb94b0fe4c4c27b029c8dc71103f61
Bug 16031: sitemap.pl shouldn't append protocol to OPACBaseURL

Since bug 5010 was pushed, OPACBaseURL already contains the protocol. The
sitemap.pl script was written before this was pushed, and thus still concatenates
http:// in front of OPACBaseURL.

This patch removes this behaviour.

To test:
- Have OPACBaseURL set to (say) http://myopac.com
- Run the sitemap.pl script without specifying the --url param
=> FAIL: Notice URLs look like http://http://myopac.com/bib... in the sitemap files.
- Apply the patch
- Run the sitemap.pl script without specifying the --url param
=> SUCCESS: Notice URLs look correctly like http://myopac.com/bib...
- Sign off :-D

Regards

Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
(cherry picked from commit 41657a87f6981516affff2f482084c7104aa34cb)
Signed-off-by: Julian Maurice <julian.maurice@biblibre.com>
misc/cronjobs/sitemap.pl