avoid panic when len(log) == 0 in colorLog func