Fixed variable causing warnings