fix jquery ref issue