Various updates

And bug fixes..