MODE-650

- Merge with latest master
- Few tweaks to code