// Finally writes the fixed content to the file.
Finally writes the fixed content to the file.
// Finally writes the fixed content to the file .
func (f *BaseFixing) Finally() error {
	diff := 0
	for _, t := range f.textEdits {
		t.Pos += diff
		t.End += diff
		f.content = append(f.content[:t.Pos], append(t.NewText, f.content[t.End+1:]...)...)
		diff += len(t.NewText) - (t.End - t.Pos + 1)
	}
	return osutil.WriteExistingFile(f.fileName, f.content)
}
func ( f * BaseFixing ) Finally ( ) error { diff := 0 for _ , t := range f . textEdits { t . Pos += diff t . End += diff f . content = append ( f . content [ : t . Pos ] , append ( t . NewText , f . content [ t . End + 1 : ] ... ) ... ) diff += len ( t . NewText ) - ( t . End - t . Pos + 1 ) } return osutil . WriteExistingFile ( f . fileName , f . content ) }
Finally writes the fixed content to the file.
Finally writes the fixed content to the file .