Crash when addind nil to an array correction