Skip to content

Commit

Permalink
update replace()
Browse files Browse the repository at this point in the history
  • Loading branch information
tj committed Nov 30, 2011
1 parent 9942e90 commit f2bffed
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions lib/nib/gradients.styl
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,13 @@
replace(expr, str, val)
expr = clone(expr)
for e, i in expr
if str == e
expr[i] = val
if length(e) > 1
expr[i] = replace(e, str, val)
else
if str == e
expr[i] = val
expr


/*
* Normalize gradient points.
*/
Expand Down

0 comments on commit f2bffed

Please sign in to comment.