Undefined variable $catid

Variable $catid does not exist and that throws PHP notice. Replacing with correct category id variable $categoryId