fixing the issues with angular snap plugin