File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -64,10 +64,10 @@ type catInfo struct {
64
64
Picurl string // 猫猫图片
65
65
}
66
66
67
- func (c * catInfo ) avatar (gid int64 ) string {
67
+ func (inf * catInfo ) avatar (gid int64 ) string {
68
68
cache := path .Join (engine .DataFolder (), "cache" )
69
- imgname := fmt .Sprintf ("%d_%d" , c .User , gid )
70
- imgfile := filepath .Join (cache , c .Type + imgname + ".png" )
69
+ imgname := fmt .Sprintf ("%d_%d" , inf .User , gid )
70
+ imgfile := filepath .Join (cache , inf .Type + imgname + ".png" )
71
71
aimgfile := filepath .Join (file .BOTPATH , imgfile )
72
72
73
73
if _ , err := os .Stat (cache ); os .IsNotExist (err ) {
@@ -78,7 +78,7 @@ func (c *catInfo) avatar(gid int64) string {
78
78
}
79
79
}
80
80
if file .IsNotExist (aimgfile ) {
81
- breed := c .Type
81
+ breed := inf .Type
82
82
data , err := web .GetData (apiURL + "search?has_breeds=" + breed )
83
83
if err != nil {
84
84
fmt .Println ("Error fetching avatar URL:" , err )
You can’t perform that action at this time.
0 commit comments