Skip to content
This repository has been archived by the owner on Apr 20, 2023. It is now read-only.

Commit

Permalink
Add check for random case where the fill.colors object doesn't exist
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason Johnston committed Aug 29, 2011
1 parent 24f662c commit ded481a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion sources/BackgroundRenderer.js
Expand Up @@ -259,7 +259,11 @@ PIE.BackgroundRenderer = PIE.RendererBase.newRenderer( {
fill['method'] = 'sigma';
fill['color'] = stops[0].color.colorValue( el );
fill['color2'] = stops[stopCount - 1].color.colorValue( el );
fill['colors'].value = vmlColors.join( ',' );
if( fill['colors'] ) { //sometimes the colors object isn't initialized so we have to assign it directly (?)
fill['colors'].value = vmlColors.join( ',' );
} else {
fill['colors'] = vmlColors.join( ',' );
}
},


Expand Down

0 comments on commit ded481a

Please sign in to comment.