fixed a bug in a way