added 3rd round of fixes