Fixes an undefined variable