Completely fixing the bug