1
0
mirror of https://github.com/fumiama/go-docx.git synced 2026-06-10 10:23:19 +08:00

make lint happy

This commit is contained in:
源文雨
2023-02-23 15:04:09 +08:00
parent fa053fefd4
commit 958a125885
9 changed files with 54 additions and 116 deletions

View File

@@ -23,8 +23,7 @@ func (r *Hyperlink) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
return err
}
switch tt := t.(type) {
case xml.StartElement:
if tt, ok := t.(xml.StartElement); ok {
if tt.Name.Local == "r" {
err = d.DecodeElement(&r.Run, &tt)
if err != nil && !strings.HasPrefix(err.Error(), "expected") {