variouos fixes and snippets