fixes for broken functions due to not-inited variables.