summaryrefslogtreecommitdiffstats
path: root/resource
diff options
context:
space:
mode:
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2018-07-16 10:42:07 +0200
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2018-07-16 10:42:07 +0200
commit4c240800a4275244c9e0847cd6707383180f1ac3 (patch)
tree795eb80f92ab01bfb9e900fcebb71094ba778cb3 /resource
parent38204c4ab6fa2aa2ab8bd06ddb3e07b66e5f9646 (diff)
resource/bundler: Improve error message
Diffstat (limited to 'resource')
-rw-r--r--resource/bundler/bundler.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/resource/bundler/bundler.go b/resource/bundler/bundler.go
index b9cd718db..4b1718b0d 100644
--- a/resource/bundler/bundler.go
+++ b/resource/bundler/bundler.go
@@ -15,7 +15,6 @@
package bundler
import (
- "errors"
"fmt"
"io"
"path/filepath"
@@ -71,7 +70,7 @@ func (c *Client) Concat(targetPath string, resources resource.Resources) (resour
// We may improve on that in the future, but then we need to know more.
for i, r := range resources {
if i > 0 && r.MediaType().Type() != resolvedm.Type() {
- return nil, errors.New("resources in Concat must be of the same Media Type")
+ return nil, fmt.Errorf("resources in Concat must be of the same Media Type, got %q and %q", r.MediaType().Type(), resolvedm.Type())
}
resolvedm = r.MediaType()
}