Bug - 5511 [Followup]: Missed Instance
authorMartin Renvoize <martin.renvoize@ptfs-europe.com>
Thu, 11 Dec 2014 13:39:24 +0000 (13:39 +0000)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Mon, 9 Feb 2015 20:00:07 +0000 (17:00 -0300)
There was an instance of the pragma missed which meant the the original
patch set didn't actually solve the problem in a large number of cases

This patch adds in the relevant statement.

Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
C4/Auth.pm

index 1238e8f..40e20f0 100644 (file)
@@ -820,7 +820,7 @@ sub checkauth {
             $userid    = undef;
             $sessionID = undef;
         }
-        elsif ( $ip ne $ENV{'REMOTE_ADDR'} ) {
+        elsif ( C4::Context->preference('SessionRestrictionByIP') && $ip ne $ENV{'REMOTE_ADDR'} ) {
 
             # Different ip than originally logged in from
             $info{'oldip'}        = $ip;