fixed a bug with the bug class