bug: tried to use a variable that didn't exist