made error and warning into views