Fix the 0 length array issue