Passing Color Attribute from Script to Shader

I am writing a simple fog shader in order to add some heavy fog to my game silent hill style. I am attempting to add an attribute to a script to control the fog color, but I keep getting this error:

Here is how I add the attribute:

Fog.attributes.add( 'fogColor', { type: 'rgb', default: [0, 0, 0], title: 'Fog Color' } );

However, when I define fogColor in the initialize function of the javascript portion of the shader instead of as an attribute, like this:

this.fogColor = [0,1,0];

The shader runs fine. Shouldn’t they act the same?
Here is the project if needed.

I was able to fix it by creating a new array with the components of this.fogColor and sending that into the shader.
I realized when setting the color inside of the initialize function I was actually just setting a normal array, not creating a Color object.