fix generateLabels in gii Generator

method substr_compare() produces an Exception: "The length must be greater than zero"
when pass "null" as $length param