intermediate commit
fixed uninitialized var bug