If you're seeing the closed message before the sql errors, then you can edit the includes/closedforums.php file to change the message.