Bugfix: type was accepted as an argument to .copy(). Added test for this.