fix #516
Merge pull request #517 from nean/pickup-patch

Changed wrong assignment