fix multiple array issue