What im trying to do is replace any common chan(s) from $3- with ones in bold for the echo.....Any help appreciated

raw 319:*:{
var %n = $sorttok($3-,32,c)
var %x = 1, %n
while ($comchan($2,%x)) {
%n = $addtok(%n,$v1,32)
inc %x
}
echo -s $str($chr(255),2) Comchans: %n
echo -si13 $str($chr(255),5) Chans: $sorttok($3-,32,c)
halt
}