Fixed unbound variable error.