fix #38 while keep compatibility with angular 1.2