mirror of
https://dev.narayana.im/narayana/telegabber.git
synced 2026-08-05 04:07:07 +00:00
Fix calculating SHA1 for photo updates
This commit is contained in:
parent
1568e29156
commit
97dfd1cc00
1 changed files with 1 additions and 1 deletions
|
|
@ -137,7 +137,7 @@ func (c *Client) processStatusUpdate(chatID int32, status string, show string, a
|
||||||
hash := sha1.New()
|
hash := sha1.New()
|
||||||
_, err = io.Copy(hash, file)
|
_, err = io.Copy(hash, file)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
photo = string(hash.Sum(nil))
|
photo = fmt.Sprintf("%x", hash.Sum(nil))
|
||||||
} else {
|
} else {
|
||||||
log.Errorf("Error calculating hash: %v", path)
|
log.Errorf("Error calculating hash: %v", path)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue