diff --git a/pkgs/erasure/decode.go b/pkgs/erasure/decode.go index d78e0ab13..bd272423f 100644 --- a/pkgs/erasure/decode.go +++ b/pkgs/erasure/decode.go @@ -112,6 +112,6 @@ func (e *Encoder) Decode(chunks [][]byte, length int) ([]byte, error) { } func Decode(block [][]byte, ep *EncoderParams, length int) ([]byte, error) { - encoder := NewEncoder(ep) + encoder := newEncoder(ep) return encoder.Decode(block, length) } diff --git a/pkgs/erasure/encode.go b/pkgs/erasure/encode.go index e1e4679b9..a224abec9 100644 --- a/pkgs/erasure/encode.go +++ b/pkgs/erasure/encode.go @@ -152,6 +152,6 @@ func (e *Encoder) Encode(block []byte) ([][]byte, int) { } func Encode(block []byte, ep *EncoderParams) ([][]byte, int) { - encoder := NewEncoder(ep) + encoder := newEncoder(ep) return encoder.Encode(block) }