invoice bug fixing