resource: Fix broken build
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Mon, 3 Sep 2018 07:22:36 +0000 (09:22 +0200)
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Mon, 3 Sep 2018 07:22:42 +0000 (09:22 +0200)
resource/bundler/bundler.go
resource/create/create.go

index 4b1718b0d82dc9499b490789f854558b6e68ca65..39ce9b521ba737ae500f5527c11021f75a975f16 100644 (file)
@@ -19,6 +19,7 @@ import (
        "io"
        "path/filepath"
 
+       "github.com/gohugoio/hugo/common/hugio"
        "github.com/gohugoio/hugo/media"
        "github.com/gohugoio/hugo/resource"
 )
@@ -36,7 +37,7 @@ func New(rs *resource.Spec) *Client {
 
 type multiReadSeekCloser struct {
        mr      io.Reader
-       sources []resource.ReadSeekCloser
+       sources []hugio.ReadSeekCloser
 }
 
 func (r *multiReadSeekCloser) Read(p []byte) (n int, err error) {
@@ -75,8 +76,8 @@ func (c *Client) Concat(targetPath string, resources resource.Resources) (resour
                        resolvedm = r.MediaType()
                }
 
-               concatr := func() (resource.ReadSeekCloser, error) {
-                       var rcsources []resource.ReadSeekCloser
+               concatr := func() (hugio.ReadSeekCloser, error) {
+                       var rcsources []hugio.ReadSeekCloser
                        for _, s := range resources {
                                rcr, ok := s.(resource.ReadSeekCloserResource)
                                if !ok {
index e9d7b6de49bd894ee95490e81c94626a00df0cb7..0f909a36d846fc52b079a4d5e1fd4b8db25c6429 100644 (file)
@@ -20,6 +20,7 @@ import (
 
        "github.com/spf13/afero"
 
+       "github.com/gohugoio/hugo/common/hugio"
        "github.com/gohugoio/hugo/resource"
 )
 
@@ -53,8 +54,8 @@ func (c *Client) FromString(targetPath, content string) (resource.Resource, erro
                        c.rs.BaseFs.Resources.Fs,
                        resource.ResourceSourceDescriptor{
                                LazyPublish: true,
-                               OpenReadSeekCloser: func() (resource.ReadSeekCloser, error) {
-                                       return resource.NewReadSeekerNoOpCloserFromString(content), nil
+                               OpenReadSeekCloser: func() (hugio.ReadSeekCloser, error) {
+                                       return hugio.NewReadSeekerNoOpCloserFromString(content), nil
                                },
                                RelTargetFilename: filepath.Clean(targetPath)})