Handle the case where a blog has no categories, so none is selected during import.
Fixing warnings about abstract static classes in PHP 5.2+
Fixing pass-by-reference errors.