Fixed define check

This was breaking on chatspaces, but this fix works!