mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-08-26 21:47:04 +00:00
Fixed: array replaceObjectsInRange:withObjectsFromArray: always failed with a "'null' is not an object' error.
This was caused by the new range checks in f8404c7a97.
This commit is contained in:
@@ -259,7 +259,7 @@ var concat = Array.prototype.concat,
|
||||
if (aRange.location < 0 || CPMaxRange(aRange) > self.length)
|
||||
[CPException raise:CPRangeException reason:_cmd + " aRange out of bounds"];
|
||||
|
||||
if (otherRange.location < 0 || CPMaxRange(otherRange) > anArray.length)
|
||||
if (otherRange && (otherRange.location < 0 || CPMaxRange(otherRange) > anArray.length))
|
||||
[CPException raise:CPRangeException reason:_cmd + " otherRange out of bounds"];
|
||||
|
||||
if (otherRange && (otherRange.location !== 0 || otherRange.length !== [anArray count]))
|
||||
|
||||
Reference in New Issue
Block a user