It doesn't seem like you need the formal parameter `fn` here since in the next line you unconditionally overwrite it.