On the script I put above, that's what this part does-

Code:
on *:JOIN:#: {
  if ( $read(dvupkeep.txt, s, $nick --) != $null ) {
    notice $nick You are still muted.
  }
  else {
    if ($me isop #) { mode # +v $nick }
  }
}


If you want it to also work with halfop, replace the isop check with:

Code:
if ($me !isreg # && $me !isvo #)


Repeat anywhere there is an isop check.