Moving the prototype sync here works b/c JavaScript hoists local funcs.