change class to error