minor cleanup / cross browser support