add safty method in caja-util