Update scripts for various issues found and general cleanup