Fixes and documentation