Issue with colors while using L-System tubes

I have an L-system and I am hoping to combine the tube mode to generate a tree trunk, alongside custom geometry assembled in the L-system itself. I have this working, but as soon as the system encounters the leaf geometry, the tube loses it’s color and I’m unable to alter the color using other commands. A screenshot is below, you can see the trunk is brown for one branch, and then white on all branches after. Switching to skeleton mode, all branches are correctly colored, so it’s a difference between skeleton and tube mode.

Any advice would be appreciated!


My l-system is this:

context_ignore:F+-
premise:FFFA

A=!"[B]//[B]//[B]//[B]//[B]//[B]
B=!!!&F&F^F L(0.4,0.2)|L(0.3,0.3)| C A
C=%:0.5
F=F

L(i,j) = g(0)[& "(i) '(j) {.+f.+f.+f.|--f.+f.}]