diff --git a/C4/Auth.pm b/C4/Auth.pm index 1238e8fdb5..40e20f04d6 100644 --- a/C4/Auth.pm +++ b/C4/Auth.pm @@ -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;