bug fixes, ready for use