Safeguard against accessing arrangedObjects array at illegal index