Minor code improvements, bugfixes