Variables reset after packaging [DEMO PROJECT INCLUDED]

Is this fixed in 4.9?