try this to test, in the init section put
echo -a file test: $lines($mircdirsystem\spam_channels.txt)

if that line comes back with nothing after the "file test" then its $null

then this should work

if ( $lines($mircdirsystem\spam_channels.txt) == $null ) { did -m protect 49 }

-b disable id
-m disables editbox