mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-03-13 16:33:28 -04:00
Gradient#setStops: improve checking for array.
This commit is contained in:
parent
06f738d4db
commit
2be70ae73f
1 changed files with 1 additions and 1 deletions
|
@ -41,7 +41,7 @@ var Gradient = this.Gradient = Base.extend({
|
|||
var rampPoint;
|
||||
var stop = stops[i];
|
||||
// If it is an array, the second argument is the rampPoint:
|
||||
if (stop.length) {
|
||||
if (Array.isArray(stop)) {
|
||||
rampPoint = stop[1];
|
||||
stop = stop[0];
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue