elsif (
# If the user logged in is the SCI user and they try to go out of the SCI module,
# kick them out unless it is SCO with a valid permission
+# or they are a superlibrarian
$in->{template_name} !~ m|sci/|
&& $user
&& haspermission( $user, { self_check => 'self_checkin_module' } )
$user, { self_check => 'self_checkout_module' }
)
)
+ && $flags && $flags->{superlibrarian} != 1
)
{
$kick_out = 1;