Bug 12573: Use correct comparison for comparing strings
authorColin Campbell <colin.campbell@ptfs-europe.com>
Mon, 14 Jul 2014 15:28:27 +0000 (16:28 +0100)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Tue, 28 Oct 2014 13:44:21 +0000 (10:44 -0300)
commitda270d9c9b199a407af59598a4ed820f311349f5
tree1f7d06d270e0bc57cc720b9d4453717e343f7e63
parent9f989999b79a765cb2177c049d6f6ea547a6300c
Bug 12573: Use correct comparison for comparing strings

Perl issues a warning when you try to do a numeric comparison on
non numeric values. While in 99% of the caeses numeric and string
comparison behave similarly when they dont tracking down resulting
bugs is hard. Also we dont want to be logging errors for normal
operations. replace numeric == with eq
(also switched to non-interpolating quotes so we dont generate
a warning from static code checkers like perlcritic)

Signed-off-by: Frederic Demians <f.demians@tamil.fr>
I can get this warnings in log files. This patch make perfectly sense.
MARC subfield code should never be tested with Perl == operator, since
the code could be letter or a number. Perl eq operator do an implicit
string conversion for value which is a number, so it will work in any
case.

Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
authorities/blinddetail-biblio-search.pl