Declare variable before using it.

I just noticed that I forgot to properly declare a variable in #285.