- Added spy.
- Improved code.