Skip to content

Commit

Permalink
lint check
Browse files Browse the repository at this point in the history
  • Loading branch information
devinyf committed Feb 24, 2024
1 parent 63b7921 commit 29a6980
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion qwen/content_audio.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,6 @@ func (acList *AudioContentList) AppendText(s string) {
(*acList)[0].Text += s
}

func (acList *AudioContentList) SetImage(url string) {
func (acList *AudioContentList) SetImage(_ string) {
panic("AudioContentList does not support SetImage")
}
10 changes: 4 additions & 6 deletions qwen/content_text.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,11 @@ func NewTextContent() *TextContent {
}

func (t *TextContent) ToBytes() []byte {
str := (*t).Text
return []byte(str)
return []byte(t.Text)
}

func (t *TextContent) ToString() string {
str := (*t).Text
return string(str)
return t.Text
}

func (t *TextContent) SetText(text string) {
Expand All @@ -36,11 +34,11 @@ func (t *TextContent) AppendText(text string) {
t.Text += text
}

func (t *TextContent) SetImage(url string) {
func (t *TextContent) SetImage(_ string) {
panic("TextContent does not support SetImage")
}

func (t *TextContent) SetAudio(url string) {
func (t *TextContent) SetAudio(_ string) {
panic("TextContent does not support SetAudio")
}

Expand Down
2 changes: 1 addition & 1 deletion qwen/content_vl.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,6 @@ func (vlist *VLContentList) AppendText(s string) {
(*vlist)[0].Text += s
}

func (vlist *VLContentList) SetAudio(url string) {
func (vlist *VLContentList) SetAudio(_ string) {
panic("VLContentList does not support SetAudio")
}

0 comments on commit 29a6980

Please sign in to comment.