Change store to only write when defined != false.
Remove mw vars, since they are not required at all.