d[h] is not a function