Why do you declare the variable here? You use if in the `if` scope but nowhere else.