That probably just means you didn’t hit “Shift-Enter” on the actual function cell to recompile the new code. Or try “Kernel → Restart and Clear Output” followed by “Cell → Run All” and see if it still fails.
Here’s a thread that is a more complete description of the “old code” problem.