Add ETag header to avatars (#721)
This commit is contained in:
parent
8093b3372e
commit
8555e888d8
7 changed files with 50 additions and 9 deletions
14
vendor/github.com/go-macaron/bindata/bindata.go
generated
vendored
14
vendor/github.com/go-macaron/bindata/bindata.go
generated
vendored
|
@ -17,13 +17,16 @@
|
|||
package bindata
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"fmt"
|
||||
"io"
|
||||
"os"
|
||||
|
||||
"github.com/elazarl/go-bindata-assetfs"
|
||||
"gopkg.in/macaron.v1"
|
||||
)
|
||||
|
||||
const _VERSION = "0.1.0"
|
||||
const _VERSION = "0.1.1"
|
||||
|
||||
func Version() string {
|
||||
return _VERSION
|
||||
|
@ -69,6 +72,15 @@ func (templates templateFileSystem) ListFiles() []macaron.TemplateFile {
|
|||
return templates.files
|
||||
}
|
||||
|
||||
func (templates templateFileSystem) Get(name string) (io.Reader, error) {
|
||||
for i := range templates.files {
|
||||
if templates.files[i].Name()+templates.files[i].Ext() == name {
|
||||
return bytes.NewReader(templates.files[i].Data()), nil
|
||||
}
|
||||
}
|
||||
return nil, fmt.Errorf("file '%s' not found", name)
|
||||
}
|
||||
|
||||
func (f *templateFile) Name() string {
|
||||
return f.name
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue