invoice bug fix