Fixed small bugs and display errors