There is a bug in this code.  Please write a test that catches the bug.