Fixed some issues that prevented compilation