diff options
author | Alexander Kiryukhin <a.kiryukhin@mail.ru> | 2020-08-17 13:42:24 +0300 |
---|---|---|
committer | Alexander Kiryukhin <a.kiryukhin@mail.ru> | 2020-08-17 13:42:41 +0300 |
commit | 4e63c622e464b6863dfec0b6c99f95833f46b12f (patch) | |
tree | f10247ecba81e44e2c77c0fb56ea01ea086d84b1 /main.go | |
parent | 3ff29e8a4ce10559a283a2f73213ea2570547b64 (diff) |
Detached AsBytes method
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -44,7 +44,11 @@ func main() { if err != nil { return err } - return c.Blob(200, "image/png", img) + blob, err := static.AsBytes(img) + if err != nil { + return err + } + return c.Blob(200, "image/png", blob) }) log.Fatal(e.Start(":8000")) } |