fixed undefined variable to allow for -u bash option.