aboutsummaryrefslogtreecommitdiff
path: root/telegram/utils.go
diff options
context:
space:
mode:
authorbodqhrohro <bodqhrohro@gmail.com>2019-12-01 16:12:55 +0300
committerbodqhrohro <bodqhrohro@gmail.com>2019-12-01 16:12:55 +0300
commit97dfd1cc00d619008eaf77f19c25c0928be758dc (patch)
tree64b32d15acfdd4f8df4b852acb7cfcba2be53477 /telegram/utils.go
parent1568e291567c2696680b23f5faf623f1d3868728 (diff)
Fix calculating SHA1 for photo updates
Diffstat (limited to 'telegram/utils.go')
-rw-r--r--telegram/utils.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/telegram/utils.go b/telegram/utils.go
index 0ae4b45..ac17906 100644
--- a/telegram/utils.go
+++ b/telegram/utils.go
@@ -137,7 +137,7 @@ func (c *Client) processStatusUpdate(chatID int32, status string, show string, a
hash := sha1.New()
_, err = io.Copy(hash, file)
if err == nil {
- photo = string(hash.Sum(nil))
+ photo = fmt.Sprintf("%x", hash.Sum(nil))
} else {
log.Errorf("Error calculating hash: %v", path)
}