Fix gradient rendering code so re-rendering works without crashing
Merge branch 'fix-gradient-rerender'