change grab function to take one map
remove dependency