shuffle and bug fixes