Fix invalid usage of $(document).on ... as 'live' function