Bug fix: amount for closing was passed when negative.