modify to use __d()