frictionlessdata / datapackage-go

A Go library for working with Data Package.
MIT License
21 stars 5 forks source link

package RemoveResource does not work #24

Closed cschloer closed 4 years ago

cschloer commented 4 years ago

Overview

Line 109 in package.go (https://github.com/frictionlessdata/datapackage-go/blob/master/datapackage/package.go#L109)

reads:

newSlice := append(rSlice[:index], rSlice[:index+1]...)

it should be

newSlice := append(rSlice[:index], rSlice[index+1:]...)

(second rSlice should be index+1: not :index+1

Currently RemoveResource actually removes every resource except for the desired resource.


Please preserve this line to notify @danielfireman (lead of this repository)

cschloer commented 4 years ago

@roll Can we add this to the project board?

roll commented 4 years ago

@cschloer done

danielfireman commented 4 years ago

Released version 1.0.1 with this fix. Thanks, @cschloer for reporting!

roll commented 4 years ago

Thanks @danielfireman !

cschloer commented 4 years ago

thank you!