Fixed issues found in last commit