Fixed error in checkFactor when only one column was present