- Added 'sell' and 'sell all' functionality
- cleaned up some code