Fix error in debug methods